pub fn is_valid_account_id(account_id: &[u8]) -> bool
Expand description
Returns true
if the given account ID is valid and false
otherwise.
ยงExamples
use near_sdk::env::is_valid_account_id;
assert_eq!(is_valid_account_id(b"test.near"), true);
assert_eq!(is_valid_account_id(b"test!.%.near"), false);