benthecarman / zapple-pay-backend

16 stars 3 forks source link

lightning emoji broken for some users #19

Closed benthecarman closed 9 months ago

alexgleason commented 9 months ago

Apparently the zap emoji can have unicode modifiers like skin color. I ended up adding this function to my bridge:

function isZapEmoji(value: string): boolean {
  return  /^\u26A1[\uFE00-\uFE0F]?$/.test(value);
}
benthecarman commented 9 months ago

Thanks, added https://github.com/benthecarman/zapple-pay-backend/commit/2c3a7c253b1e0bc996a50e5f64fc589eb660c03c