• This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn more.

Fixed Unable to add media unless member already has an album

Affected version

Mr Lucky

Well-known member
A member who has permissions to add media, but has not yet created an album, gets an error message when clicking on Add media button. Other members with same usergroups can add media into an existing album

We ran into some problems.

You do not have permission to view this page or perform this action.

Mr Lucky

Well-known member
Yes I analayzed permissions, the test user has correct permissions.

With a test user I could upload media to his album.

Then as admin I deleted that test user's album, and then the test user was no longer able to uploaod, and got the error message as above.

(This was the same parmissions as the user who reported te problem, who had not yet created an album)

Users who already have an album have no problems uploading to their albums.
Last edited:

Chris D

XenForo developer
Staff member
This is fixed now for the next release.

To fix now, open the file src/addons/XFMG/Pub/Controller/Media.php and find:
if (!$categoryAddTree->count() && !$canAddToAlbums)
And change that to:
if (!$categoryAddTree->count() && !$canAddToAlbums && !($visitor->canCreateAlbum() && $this->options()->xfmgAllowPersonalAlbums))