bugfix with tag queries
This commit is contained in:
@@ -995,11 +995,17 @@ async fn status(req: HttpRequest) -> Result<impl web::Responder, web::Error> {
|
||||
}
|
||||
|
||||
async fn videos_post(
|
||||
video_request: web::types::Json<VideosRequest>,
|
||||
mut video_request: web::types::Json<VideosRequest>,
|
||||
cache: web::types::State<VideoCache>,
|
||||
pool: web::types::State<DbPool>,
|
||||
requester: web::types::State<Requester>,
|
||||
) -> Result<impl web::Responder, web::Error> {
|
||||
match video_request.query.as_deref() {
|
||||
Some(query) if query.starts_with("#") => {
|
||||
video_request.query = Some(query.trim_start_matches("#").to_string());
|
||||
}
|
||||
_ => {}
|
||||
}
|
||||
let requester = requester.get_ref().clone();
|
||||
let mut conn = pool.get().expect("couldn't get db connection from pool");
|
||||
// Ensure "videos" table exists with two string columns
|
||||
|
||||
Reference in New Issue
Block a user