Skip to content
This repository was archived by the owner on Feb 3, 2025. It is now read-only.

Conversation

@glogiotatidis
Copy link
Contributor

No description provided.

@glogiotatidis
Copy link
Contributor Author

@Osmose r?

@Osmose
Copy link
Contributor

Osmose commented Oct 23, 2014

@jgmize You think you can handle reviewing this?

@Osmose
Copy link
Contributor

Osmose commented Oct 28, 2014

Apparently not. I'm back!

@Osmose Osmose self-assigned this Oct 28, 2014
@jgmize
Copy link
Contributor

jgmize commented Oct 28, 2014

Sorry I wasn't able to get to this for you while you were on vacation, @Osmose.

@Osmose
Copy link
Contributor

Osmose commented Oct 28, 2014

No prob bob

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Assuming these are images is a bad idea; we'll probably use this for videos soon after, and maybe someday even more than that. Just a link would probably be fine.

@glogiotatidis glogiotatidis force-pushed the images branch 2 times, most recently from cc049cb to 80b87b9 Compare October 29, 2014 12:32
@glogiotatidis
Copy link
Contributor Author

Unfortunately factory_boy FileField doesn't work as advertized (generated objects don't have filename) so I ended up mocking a few things here
glogiotatidis@80b87b9#diff-2a900c8e171c7001a9fabecc7bf9671eR213

and here glogiotatidis@80b87b9#diff-2a900c8e171c7001a9fabecc7bf9671eR222

Not a big problem, just explaining why I did it this way.

@glogiotatidis
Copy link
Contributor Author

Also I added a clean_file method to UploadedFileAdminForm to validate that when user's updating an existing UploadedFile obj, the new uploaded file extension matches the current one.

Background: I mistakenly updated an image UploadedFile with a pdf, because both of them get previewed in the File Manager. Since we keep the same filename, the file was served as jpg and firefox claimed that the file was corrupted.

glogiotatidis@80b87b9#diff-7f9584d4e3d5f36896f37dfa5d87ed78R145

@glogiotatidis glogiotatidis force-pushed the images branch 2 times, most recently from 3f28d20 to aaa45ec Compare October 29, 2014 12:50
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Could just return here and below instead of using the variable.

@Osmose
Copy link
Contributor

Osmose commented Oct 29, 2014

r+wc, looks nice!

@glogiotatidis glogiotatidis force-pushed the images branch 3 times, most recently from 8cb2475 to ea6a0f1 Compare November 4, 2014 15:10
@glogiotatidis glogiotatidis force-pushed the images branch 2 times, most recently from 04ffe13 to a761e32 Compare November 5, 2014 09:38
glogiotatidis added a commit that referenced this pull request Nov 5, 2014
 [fix bug 1082208] Support media files and CDN.
@glogiotatidis glogiotatidis merged commit f09c63d into mozmeao:master Nov 5, 2014
@glogiotatidis glogiotatidis deleted the images branch December 2, 2015 10:37
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants