Skip to content

Commit cf1915e

Browse files
NooNoo1337tshemsedinov
authored andcommitted
fix all delete queries
1 parent fb4a924 commit cf1915e

File tree

6 files changed

+6
-6
lines changed

6 files changed

+6
-6
lines changed

JavaScript/4-service/db.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -53,7 +53,7 @@ module.exports = (table) => ({
5353
},
5454

5555
delete(id) {
56-
const sql = 'DELETE FROM ${table} WHERE id = $1';
56+
const sql = `DELETE FROM ${table} WHERE id = $1`;
5757
return pool.query(sql, [id]);
5858
},
5959
});

JavaScript/5-agnostic/db.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -53,7 +53,7 @@ module.exports = (table) => ({
5353
},
5454

5555
delete(id) {
56-
const sql = 'DELETE FROM ${table} WHERE id = $1';
56+
const sql = `DELETE FROM ${table} WHERE id = $1`;
5757
return pool.query(sql, [id]);
5858
},
5959
});

JavaScript/6-ws/db.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -53,7 +53,7 @@ module.exports = (table) => ({
5353
},
5454

5555
delete(id) {
56-
const sql = 'DELETE FROM ${table} WHERE id = $1';
56+
const sql = `DELETE FROM ${table} WHERE id = $1`;
5757
return pool.query(sql, [id]);
5858
},
5959
});

JavaScript/7-fs/db.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -53,7 +53,7 @@ module.exports = (table) => ({
5353
},
5454

5555
delete(id) {
56-
const sql = 'DELETE FROM ${table} WHERE id = $1';
56+
const sql = `DELETE FROM ${table} WHERE id = $1`;
5757
return pool.query(sql, [id]);
5858
},
5959
});

JavaScript/8-vm/db.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -53,7 +53,7 @@ module.exports = (table) => ({
5353
},
5454

5555
delete(id) {
56-
const sql = 'DELETE FROM ${table} WHERE id = $1';
56+
const sql = `DELETE FROM ${table} WHERE id = $1`;
5757
return pool.query(sql, [id]);
5858
},
5959
});

JavaScript/9-logger/db.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -53,7 +53,7 @@ module.exports = (table) => ({
5353
},
5454

5555
delete(id) {
56-
const sql = 'DELETE FROM ${table} WHERE id = $1';
56+
const sql = `DELETE FROM ${table} WHERE id = $1`;
5757
return pool.query(sql, [id]);
5858
},
5959
});

0 commit comments

Comments
 (0)