fix(frontend): search user with trailing space (#11184)

* fix(frontend): search user with trailing space

* fix(backend): search user with trailing space

* Update search.ts

---------

Co-authored-by: syuilo <Syuilotan@yahoo.co.jp>
This commit is contained in:
nomad 2023-07-08 16:41:52 +08:00 committed by GitHub
parent 0fbb46c981
commit e40a0b98e4
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
4 changed files with 5 additions and 2 deletions

View file

@ -91,6 +91,7 @@ export default class extends Endpoint<typeof meta, typeof paramDef> {
let user;
const isModerator = await this.roleService.isModerator(me);
ps.username = ps.username?.trim();
if (ps.userIds) {
if (ps.userIds.length === 0) {