mirror of
https://github.com/zadam/trilium.git
synced 2025-11-17 18:50:41 +01:00
chore(routes): fix no-explicit-any lint/ts error for catch blocks
This commit is contained in:
@@ -56,10 +56,10 @@ function execute(req: Request) {
|
||||
success: true,
|
||||
results
|
||||
};
|
||||
} catch (e: any) {
|
||||
} catch (e: unknown) {
|
||||
return {
|
||||
success: false,
|
||||
error: e.message
|
||||
error: (e instanceof Error) ? e.message : "Unknown Error"
|
||||
};
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user