String remove0x(String hex) { if (hex.startsWith('0x') || hex.startsWith('0X')) { return hex.substring(2); } return hex; }