Pure spaces == internal error (cause the userID is in the URL, and express expects something, so /user/bla is fine but /user/ doesn't trigger the same route. Fix by not querying on empty user filters OR not allowing the user to hit space on the first key.
Space is not the only issue, I'm realizing it's a poor design to have user input be in the URL like this. For example what if the user input had / or \
Pure spaces == internal error (cause the userID is in the URL, and express expects something, so
/user/bla
is fine but/user/
doesn't trigger the same route. Fix by not querying on empty user filters OR not allowing the user to hit space on the first key.