Support from Acquia helps fund testing for Drupal Acquia logo

Comments

jhedstrom’s picture

Status: Needs work » Needs review
FileSize
3.65 KB

Replacing a few more instances of media_access with file_access.

Jackinloadup’s picture

fixed some hook_menu arguments

jpstrikesback’s picture

Tested uploads, working great

gooddesignusa’s picture

This patch doesn't seem to apply to the latest dev of 2012-Aug-25.
If you use http://drupalcode.org/project/media.git/tree/1a0304dc62a468cf3fef7559cd6...
the patch applies cleanly.

Jackinloadup’s picture

all the changes are due to #1293908: Respect file type restrictions in media browser library view getting in ^_^

attached is a here is a reroll

I changed all the places where we asked for 'edit' privileges to 'update'

Jackinloadup’s picture

Status: Needs review » Postponed

I'm going to mark this as postponed as we can't do reviews until #1227706: Add a file entity access API is in anyway.

gooddesignusa’s picture

Thanks for rerolled patch. It seems that upload tab for the media browser still wont show unless the user has the permission 'Administer files'. I verified I did apply the file_entity-file-access-1227706-71.patch from the other thread. I did notice there was a newer patch. I reversed the above patch and applied file_entity-file-access-1227706-78.patch. I also applied the patch from http://drupal.org/node/1422260#comment-6415726. Flushed cache and still no luck.

jhedstrom’s picture

Patch from #5 still had a lingering call to media_access() in MediaBrowserUpload.

jpstrikesback’s picture

Status: Postponed » Needs review

Let's get #8 tested (changing status)

gooddesignusa’s picture

file_access needed to be updated to file_entity_access. The naming got changed a couple patches ago.
I did test it the latest patch http://drupal.org/node/1227706#comment-6627060 and it seems to be working.
I manually edited the patch and swapped out file_access, should still work fine. I've never manually edited a .patch file before.

ParisLiakos’s picture

Title: Use file_access() instead of media_access() » Use file_entity_access() instead of media_access()
Status: Needs review » Fixed

thanks all, commited with some changes

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.

David_Rothstein’s picture

The changes on commit look like they introduced a bug; see #1877214: Media browser upload plugin permission check is incorrect.