You've already forked joplin
mirror of
https://github.com/laurent22/joplin.git
synced 2025-11-26 22:41:17 +02:00
This commit is contained in:
@@ -84,6 +84,13 @@ export default class Database {
|
||||
return output;
|
||||
}
|
||||
|
||||
public escapeValues(values: string[]) {
|
||||
return values.map(value => {
|
||||
// See https://www.sqlite.org/printf.html#percentq
|
||||
return `'${value.replace(/[']/g, '\'\'')}'`;
|
||||
});
|
||||
}
|
||||
|
||||
public escapeFieldsToString(fields: string[] | string): string {
|
||||
if (typeof fields === 'string') {
|
||||
if (fields === '*') return '*';
|
||||
|
||||
Reference in New Issue
Block a user