eyre: bind most specific endpoint first

This sticks to the old behavior, which was briefly lost in recent
changes.
This commit is contained in:
Fang 2021-09-25 17:44:31 +04:00
parent 7d3fc3d9b1
commit 4ed2a5914b
No known key found for this signature in database
GPG Key ID: EB035760C1BBA972
2 changed files with 6 additions and 4 deletions

View File

@ -1,3 +1,3 @@
version https://git-lfs.github.com/spec/v1 version https://git-lfs.github.com/spec/v1
oid sha256:99ac1fbddddaad25d3275d1308f5f3814f4e586501fb0233915b8191c8221415 oid sha256:9d43082531afe722b06c5ada13f8c7cc98d2c4b5ac6a58dc0a13282bb69f4384
size 12589812 size 12699810

View File

@ -2118,8 +2118,8 @@
?: new-before-bid [new bindings] ?: new-before-bid [new bindings]
[i.bindings $(bindings t.bindings)] [i.bindings $(bindings t.bindings)]
?: =(site.binding.new site.bid) ?: =(site.binding.new site.bid)
(aor path.binding.new path.bid) (aor path.bid path.binding.new)
(aor (fall site.binding.new '') (fall site.bid '')) (aor (fall site.bid '') (fall site.binding.new ''))
:: ::
++ channel-wire ++ channel-wire
|= [channel-id=@t request-id=@ud] |= [channel-id=@t request-id=@ud]
@ -2163,6 +2163,8 @@
:: initial value for the login handler :: initial value for the login handler
:: ::
=. bindings.server-state.ax =. bindings.server-state.ax
=- (roll - insert-binding)
^- (list [binding ^duct action])
:~ [[~ /~/login] duct [%authentication ~]] :~ [[~ /~/login] duct [%authentication ~]]
[[~ /~/logout] duct [%logout ~]] [[~ /~/logout] duct [%logout ~]]
[[~ /~/channel] duct [%channel ~]] [[~ /~/channel] duct [%channel ~]]