Authorization 2.0 contains new features and a few breaking changes.
IdentityInterface has had typehinting added. If you have implemented the
IdentityInterface you will need to update your application’s implementation
to reflect the new typehints.
In addition to typehints
IdentityInterface has a
added. This method always returns a
ResultInterface object while
always returns a boolean. In 1.x the
can() method would return a boolean or
ResultInterface depending on what the policy returned. This made knowing the
return value of
can() very hard. The new methods and additional typings
IdentityInterface simpler and more reliable to use.