Skip to content

Commit

Permalink
Merge pull request #13513 from colemanw/Fix
Browse files Browse the repository at this point in the history
Fix undefined throwing error in CRM.checkPerm
  • Loading branch information
eileenmcnaughton authored Jan 30, 2019
2 parents da667a5 + 3d6e14f commit bc4b7a4
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion js/Common.js
Original file line number Diff line number Diff line change
Expand Up @@ -1497,7 +1497,7 @@ if (!CRM.vars) CRM.vars = {};
// Determine if a user has a given permission.
// @see CRM_Core_Resources::addPermissions
CRM.checkPerm = function(perm) {
return CRM.permissions[perm];
return CRM.permissions && CRM.permissions[perm];
};

// Round while preserving sigfigs
Expand Down

0 comments on commit bc4b7a4

Please sign in to comment.