digitalbazaar / ezcap

An opinionated Authorization Capabilities client
BSD 3-Clause "New" or "Revised" License
7 stars 1 forks source link

Throw if both `url` and `capability` are passed to `delegate()` #12

Closed dlongley closed 2 years ago

dlongley commented 2 years ago

Both of these params should not be passed at the same time. If capability is passed and the caller wants to attenuate the invocationTarget, they are supposed to pass that param. This API could be improved; I wonder if the url param should be removed and only invocationTarget should be used instead -- as it would work fine if no capability were passed, generating a root zcap URN in that case (just like if you only pass url).

dlongley commented 2 years ago

Addressed by #14.