Skip to content

Commit

Permalink
resolve isENS without case sensitivity (#2545) (#2568)
Browse files Browse the repository at this point in the history
Co-authored-by: ricky <ricky.miller@gmail.com>

Co-authored-by: Minh <minhle@canva.com>
  • Loading branch information
rickycodes and Pixeladed authored Apr 22, 2021
1 parent 6cbea59 commit e498508
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion app/util/address.js
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,7 @@ export async function importAccountFromPrivateKey(private_key) {
*/
export function isENS(name) {
const rec = name && name.split('.');
if (!rec || rec.length === 1 || !AppConstants.supportedTLDs.includes(rec[rec.length - 1])) {
if (!rec || rec.length === 1 || !AppConstants.supportedTLDs.includes(rec[rec.length - 1].toLowerCase())) {
return false;
}
return true;
Expand Down

0 comments on commit e498508

Please sign in to comment.