After update to ember 3.27.5 there is an error: Uncaught TypeError: (0 , _string.isHTMLSafe) is not a function
enterpub opened this issue · comments
Fails on any page with validation
Uncaught TypeError: (0 , _string.isHTMLSafe) is not a function
at unwrapString (utils.js:36)
at Class.createErrorMessage (base.js:208)
at Class.validate (ember-validator.js:14)
at factory.js:366
at factory.js:452
at Array.map (<anonymous>)
at generateValidationResultsFor (factory.js:430)
at Class.<anonymous> (factory.js:365)
at Class.<anonymous> (cycle-breaker.js:26)
at index.js:1935
In utils.js (ember-cp-validations/utils/utils)
fails on this line:
function unwrapString(s) {
if ((0, _string.isHTMLSafe)(s)) { // <<<------ fails here
return s.toString();
}
return s;
}
How to fix this issue? Thank you
Environment
- Ember Version: 3.27.5
- Ember CLI Version: 3.27
- Ember CP Validations Version: 4.0.0-beta.12
Steps to Reproduce
Any page where validation occures
Emer-cp-validations still work with ember 3.26.1
Please test this PR: #699.
yarn add -D lolmaus/ember-cp-validations#lolmaus:issue-698-isHTMLSafe
(Do not depend on the branch in production. The branch will be removed, and your builds will start failing. Create your own fork and depend on it instead.)
@lolmaus , thank you for youer effort. I'll be able to check the fix later, at least in a week. I've looked at the changes you've made and I'm sure that should fix the issue
Hi, wonder when the fix for this issue could be merged?
The project seems to be unmaintained.
@enterpub that should be fixed in the new beta release so I guess we can close the issue.
@fsmanuel I will check the fix next week, but I believe it may be closed. Thank you
@enterpub I'm closing this. Feel free to reopen if there are still problems.