[ckan-changes] [ckan/ckan] 360f82: fix the relationship_create auth method
GitHub
noreply at github.com
Tue Jul 18 12:53:55 UTC 2017
Branch: refs/heads/master
Home: https://github.com/ckan/ckan
Commit: 360f82ff6479a08229820fd733360711e5167966
https://github.com/ckan/ckan/commit/360f82ff6479a08229820fd733360711e5167966
Author: yixuan zhao <120559187 at qq.com>
Date: 2017-07-15 (Sat, 15 Jul 2017)
Changed paths:
M ckan/logic/auth/create.py
Log Message:
-----------
fix the relationship_create auth method
the code below
```
if not authorized1 and authorized2:
return {'success': False, 'msg': _('User %s not authorized to edit these packages') % user}
else:
return {'success': True}
```
didn't work when authorized1 == authorized2 == False which presented that user cannot access to both packages(datasets).
It would be : `if not False and False` -> `if True and False` -> `if Fasle`, then return `'success' : True`
Commit: fac76d6bf81401fef4f1eb24cb7631747da3c9b8
https://github.com/ckan/ckan/commit/fac76d6bf81401fef4f1eb24cb7631747da3c9b8
Author: Adrià Mercader <amercadero at gmail.com>
Date: 2017-07-18 (Tue, 18 Jul 2017)
Changed paths:
M ckan/logic/auth/create.py
Log Message:
-----------
Merge pull request #3696 from polomi-dataworks/master
fix the relationship_create auth method
Compare: https://github.com/ckan/ckan/compare/e40fac6e1cc8...fac76d6bf814
More information about the ckan-changes
mailing list