Needs work
Project:
Node Profile
Version:
5.x-1.x-dev
Component:
Code
Priority:
Normal
Category:
Feature request
Assigned:
Unassigned
Reporter:
Created:
20 Jun 2007 at 11:35 UTC
Updated:
21 Jun 2007 at 19:47 UTC
Currently, users must have the "create type content" access right to edit their profile node.
If users only have the "edit own content type" access right, a blank form is shown when editing their profile.
The attached patch did the trick for me.
It replaces node_access('create', $category) with user_access('edit own '. $category .' content').
| Comment | File | Size | Author |
|---|---|---|---|
| nodeprofile_edit_own_profile.patch | 1.04 KB | Moxide |
Comments
Comment #1
fagohm, if, it has to be node_access('update', $node) - but in this line of code, it might be both - creating and editing. The checks have to be later, when we know if $node is there. to make this clean, also the returned user categories must map to the access rights.
So in short, some more changes would be required, for which I've currently not the time. However, I'd be happy to receive a (clean) patch.