changing media type deletes resource of previous type without deploy #22

Open
opened 2025-05-19 12:15:34 -05:00 by ITwrx · 1 comment
Owner

When a user changes the media type for a page, it deletes the old media type to keep from having unused files piling up on the filesystem. That's all well and good, but since it deletes without a "site deploy" the site doesn't have the image anymore for the still currently-deployed site. Will have to refactor to prevent that from happening, as changing/saving new site state without it affecting the live site without "site deploy" is supported.

Until this issue is closed users might want to avoid changing their media unless they are also going to do a site deploy immediately following.

When a user changes the media type for a page, it deletes the old media type to keep from having unused files piling up on the filesystem. That's all well and good, but since it deletes without a "site deploy" the site doesn't have the image anymore for the still currently-deployed site. Will have to refactor to prevent that from happening, as changing/saving new site state without it affecting the live site without "site deploy" is supported. Until this issue is closed users might want to avoid changing their media unless they are also going to do a site deploy immediately following.
ITwrx added the
design flaw
investigating
labels 2025-05-19 12:15:34 -05:00
ITwrx added
fix in dev
and removed
investigating
labels 2025-05-30 09:45:47 -05:00
Author
Owner

This has been refactored in dev and now deletes the unused media on site deploy. An interesting side effect is that now when you're editing a page, SSM "remembers" any media you add to the page, so when you change the mediaType and save the page, the media for the previous media type is still there if you switch back. This freaked me out at first, as i thought more redesign would be necessary, but it's actually a fairly logical behavior, as all the media you add for a page is there unless you choose to delete it, but SSM will delete unused mediaTypes when you deploy, as keeping staged videos around for no good reason will use too much space.

This has been refactored in dev and now deletes the unused media on site deploy. An interesting side effect is that now when you're editing a page, SSM "remembers" any media you add to the page, so when you change the mediaType and save the page, the media for the previous media type is still there if you switch back. This freaked me out at first, as i thought more redesign would be necessary, but it's actually a fairly logical behavior, as all the media you add for a page is there unless you choose to delete it, but SSM will delete unused mediaTypes when you deploy, as keeping staged videos around for no good reason will use too much space.
ITwrx removed the
design flaw
label 2025-06-06 10:50:33 -05:00
Sign in to join this conversation.
No Milestone
No project
No Assignees
1 Participants
Notifications
Due Date
The due date is invalid or out of range. Please use the format 'yyyy-mm-dd'.

No due date set.

Dependencies

No dependencies set.

Reference: ITwrxOrg/SimpleSiteManager#22
No description provided.