pub fn only_owner() 
Expand description

Ensures that the sender is the owner.

Reverts

  • When the sender is not the owner.

Number of Storage Accesses

  • Reads: 1

Examples

use sway_libs::ownership::only_owner;

fn foo() {
    only_owner();
    // Do stuff here
}