revoltchat / backend

Monorepo for Revolt backend services.
https://developers.revolt.chat/api/
Other
1.14k stars 125 forks source link

feat: search by author #249

Closed ERROR-404-NULL-NOT-FOUND closed 10 months ago

ERROR-404-NULL-NOT-FOUND commented 1 year ago

Please make sure to check the following tasks before opening and submitting a PR

github-actions[bot] commented 1 year ago

CLA Assistant Lite bot All contributors have signed the CLA ✍️ ✅

ERROR-404-NULL-NOT-FOUND commented 1 year ago

I have read the CLA Document and I hereby sign the CLA

toastxc commented 1 year ago

I think the lengths should be set by using length/eq instead of assigning a max and min value, which for ID (given that it must be exactly 24 chars) makes more sense.

example

#[derive(Validate, Serialize, Deserialize, JsonSchema)]
pub struct OptionsMessageSearch {
    #[validate(length(equal = "24"))]
    author: Option<String>,
}

It's a minor change, but it makes code a bit cleaner

insertish commented 10 months ago

Also there is a conflict.

ERROR-404-NULL-NOT-FOUND commented 10 months ago

Idk what you expected when you let a PR sit for this long lmao Y'all have said that you aren't going to merge it due to technical debt, so I'm just going to close this