klaytn/caver-js

stripHexPrefix sometimes not working properly

Closed this issue · 0 comments

Describe the bug
Sometimes the expected result with the stripHexPrefix function is different.

How to reproduce
caver.utils.stripHexPrefix('0x2de402c403eef2b7bdb39d2988e929117304e82f577d98bff6f8bf07ba08200e0x000x2dbe5e9c134afbbda42c04c94ae630a59cfd0672')

0x2de402c403eef2b7bdb39d2988e929117304e82f577d98bff6f8bf07ba08200e0x000x2dbe5e9c134afbbda42c04c94ae630a59cfd0672

Expected behavior
caver.utils.stripHexPrefix('0x2de402c403eef2b7bdb39d2988e929117304e82f577d98bff6f8bf07ba08200e0x000x2dbe5e9c134afbbda42c04c94ae630a59cfd0672')

2de402c403eef2b7bdb39d2988e929117304e82f577d98bff6f8bf07ba08200e0x000x2dbe5e9c134afbbda42c04c94ae630a59cfd0672

Attachments
If applicable, add data, logs or screenshots to help explain your problem.

Environment (please complete the following information)

  • caver-js v1.1.2
  • macOS/10.14

Additional context
Add any other context about the problem here.