You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
See error - results doesn't show false as stated in documentation but log uncaught error in console
Expected behavior Typecheck is a publicly exported function in Schema class. Documentation of the Typecheck has defined it's output to be true/false now the behaviour is return undefined or throw error
Since the refactor of producing unexpected behaviour till discovery now has been 4m that I'll assume people don't use Typecheck method in their codebase (didn't break people's code) but was used as a util function to determine what to input for storage value.
I think Typecheck method should at least return true when checkout but when it comes to false whether if it's a better practice to throw error directly or console.log(error) and return false is up for discussion
Screenshots
If applicable, add screenshots to help explain your problem.
Description
Typecheck
method inSchema
class used to return true/false this behaviour has been changed in a previous refactorSteps To Reproduce
Steps to reproduce the behavior:
Expected behavior
Typecheck
is a publicly exported function in Schema class. Documentation of theTypecheck
has defined it's output to betrue
/false
now the behaviour is returnundefined
or throw errorSince the refactor of producing unexpected behaviour till discovery now has been 4m that I'll assume people don't use
Typecheck
method in their codebase (didn't break people's code) but was used as a util function to determine what to input for storage value.I think
Typecheck
method should at least return true when checkout but when it comes to false whether if it's a better practice to throw error directly orconsole.log(error)
and returnfalse
is up for discussionScreenshots
If applicable, add screenshots to help explain your problem.
Additional context
the pr of the behaviour change to reference what typecheck used to be
https://github.com/ecadlabs/taquito/pull/2551/files#diff-d381c6954cea4e63fa67739ae43adcdc2246cd50ee465023d2a2be5d8bded4ed
The text was updated successfully, but these errors were encountered: