dspace-angular icon indicating copy to clipboard operation
dspace-angular copied to clipboard

Model classes should not contain any logic

Open alexandrevryghem opened this issue 1 year ago • 0 comments

Describe the bug Currently some components have methods in their classes. This can cause issues when nested object are copied from the SSR cache to the CSR cache. We recently had this happen for the MetadataValue model class. This can easily be fixed by moving that logic to a service and calling that service with the object instead.

Expected behavior Those methods should be moved out of these model classes into new/existing services

alexandrevryghem avatar Mar 22 '24 12:03 alexandrevryghem