Skip to content

Commit

Permalink
[REF] web: Remove is_admin key in session info
Browse files Browse the repository at this point in the history
Because of its redundency with is_system key.
  • Loading branch information
tivisse committed Dec 2, 2016
1 parent d1bd102 commit 8789188
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 2 deletions.
1 change: 0 additions & 1 deletion addons/web/models/ir_http.py
Expand Up @@ -26,7 +26,6 @@ def session_info(self):
"session_id": request.session.sid,
"uid": request.session.uid,
"is_system": request.env.user._is_system(),
"is_admin": request.env.user.has_group('base.group_system'),
"is_superuser": request.env.user._is_superuser(),
"user_context": request.session.get_context() if request.session.uid else {},
"db": request.session.db,
Expand Down
2 changes: 1 addition & 1 deletion addons/web/static/src/js/widgets/debug_manager.js
Expand Up @@ -64,7 +64,7 @@ var DebugManager = Widget.extend({
// whether group is currently enabled for current user
this._has_features = false;
// whether the current user is an administrator
this._is_admin = session.is_admin;
this._is_admin = session.is_system;
return $.when(
new Model('res.users').call('check_access_rights', {operation: 'write', raise_exception: false}),
session.user_has_group('base.group_no_one'),
Expand Down

0 comments on commit 8789188

Please sign in to comment.