Revision 3004
Added by sgarg over 18 years ago
src/edu/ucsb/nceas/metacat/DocumentImpl.java | ||
---|---|---|
2324 | 2324 |
|
2325 | 2325 |
if (action.equals("UPDATE")) { |
2326 | 2326 |
// check for 'write' permission for 'user' to update this document |
2327 |
if (!hasWritePermission(user, groups, accnum)) { |
|
2327 |
if (!hasWritePermission(user, groups, accnum) |
|
2328 |
&& !MetaCatUtil.isAdministrator(user, groups)) { |
|
2328 | 2329 |
throw new Exception( |
2329 | 2330 |
"User " + user |
2330 | 2331 |
+ " does not have permission to update XML Document #" |
src/edu/ucsb/nceas/metacat/Eml200SAXHandler.java | ||
---|---|---|
317 | 317 |
// we need to check if user update access subtree |
318 | 318 |
if (action != null && action.equals("UPDATE") |
319 | 319 |
&& !control.hasPermission(user, groups, |
320 |
AccessControlInterface.ALLSTRING)) |
|
320 |
AccessControlInterface.ALLSTRING) |
|
321 |
&& !MetaCatUtil.isAdministrator(user, groups)) |
|
321 | 322 |
{ |
322 | 323 |
needCheckingAccessModule = true; |
323 | 324 |
unChangebleTopAccessSubTree = getTopAccessSubTreeFromDB(); |
Also available in: Unified diff
Allow admin to update any document