export function getSecret20ViewingKeyPermissionType ( contractAddress ) { return `viewing-key/${ contractAddress }` ; } export function isSecret20ViewingKeyPermissionType ( type ) { return type . startsWith ( "viewing-key/" ) ; } export function splitSecret20ViewingKeyPermissionType ( type ) { return type . replace ( "viewing-key/" , "" ) ; }