Closed matheo closed 7 years ago
There is an infinite loop, but it isn't due to the timezone but by a circular watch between two fields of the same scope.
I fix it with the PR #1318, which supersede this one.
Thanks for contributing!
Infinite loop caused by the timezone changing the original value, indeed, inside the circular watch. Once Date() changes the rawValue, it's all messed up, but the angular.equals
check seems legit to prevent that too.
I confirmed that 1.0.1 works, thanks a lot! Best regards
There's an infinite loop $watching value and rawValue, because the
Date
object adjust theyyyy-mm-dd
value to the user's timezone, then modifying the original value +- the timezone. This patch adjust the timezone, so the rawValue is kept as the original value.