Publish photos to your own blog — hosted by Micro.blog or compatible blogs using WordPress or Micropub — and discover beautiful photos from other users.
Whilst experimenting with Sunlit, I noticed that image and movie uploads to an external micropub endpoint always use the filename: image.jpg and movie.mov respectively.
On examining the source, I noticed that uploads to XMLRPC endpoints however don't and instead use a UUID-derived filename:
This PR implements the same logic for micropub image and movie uploads.
Note: this PR targets the 3.2 branch as I believe master represents the current stable 3.0 release. I can re-target if you'd prefer this to target master.
Whilst experimenting with Sunlit, I noticed that image and movie uploads to an external micropub endpoint always use the filename:
image.jpg
andmovie.mov
respectively.On examining the source, I noticed that uploads to XMLRPC endpoints however don't and instead use a UUID-derived filename:
https://github.com/microdotblog/sunlit/blob/65567259f39b4739e1e80e40b3195aeaf426f9a4/Libraries/Snippets/Snippets%2BXMLRPC.swift#L158
https://github.com/microdotblog/sunlit/blob/65567259f39b4739e1e80e40b3195aeaf426f9a4/Libraries/Snippets/Snippets%2BXMLRPC.swift#L205
This PR implements the same logic for micropub image and movie uploads.
Note: this PR targets the
3.2
branch as I believemaster
represents the current stable 3.0 release. I can re-target if you'd prefer this to targetmaster
.Fixes https://github.com/microdotblog/sunlit/issues/131