add `isServer` to middleware context