Skip to content
Snippets Groups Projects
Commit 29ab2e89 authored by Fabien Zucchet's avatar Fabien Zucchet
Browse files

Try to fix SQL injections

parent 7a3de497
No related branches found
No related tags found
No related merge requests found
......@@ -30,7 +30,7 @@ function getAdministrateurs(req, res) {
function addNewAdministrateur(req, res) {
var con = mysql.createConnection(dbConfig);
var query = "INSERT INTO `Admin` (`login`) VALUES (?);";
var query = "INSERT INTO `Admin` (`login`) VALUES (?)";
var inserts = [req.body.login];
con.connect();
con.query(query, inserts, (err, result) => {
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment