MCPcopy Create free account
hub / github.com/dfinity/orbit / is_admin

Method is_admin

core/control-panel/impl/src/core/call_context.rs:69–71  ·  view source on GitHub ↗

Checks if the caller is an admin.

(&self)

Source from the content-addressed store, hash-verified

67
68 /// Checks if the caller is an admin.
69 pub fn is_admin(&self) -> bool {
70 self.is_self() || self.is_controller()
71 }
72
73 /// Checks if the caller is the asset canister.
74 pub fn assert_is_admin(&self, scope: &str) -> Result<(), CanisterError> {

Callers 3

use_is_authorized_adminFunction · 0.80
assert_is_adminMethod · 0.80
assert_user_accessMethod · 0.80

Calls 2

is_selfMethod · 0.80
is_controllerMethod · 0.80

Tested by

no test coverage detected