Shortcoming with the http server impl was discovered specifically when dealing with SPAs:
For example:
Chainmail is registered as an SPA, so any request that doesn't specify an extension (which would imply a request for a static asset e.g. style.css) it assumes is a client route and returns the root document. But that means that API requests like /messages/sender=alice are just returning the root document.
This PR reverses the order in which the servers are checked, checking the registered server first. Only check sites iff the registered server returns None.
Shortcoming with the http server impl was discovered specifically when dealing with SPAs:
For example: Chainmail is registered as an SPA, so any request that doesn't specify an extension (which would imply a request for a static asset e.g.
style.css
) it assumes is a client route and returns the root document. But that means that API requests like/messages/sender=alice
are just returning the root document.This PR reverses the order in which the servers are checked, checking the registered server first. Only check sites iff the registered server returns
None
.