Corrected bug on 404

This commit is contained in:
Thomas FORGIONE 2015-06-22 14:48:44 +02:00
parent 00bb56fee8
commit ebc30a3bc5
1 changed files with 1 additions and 1 deletions

View File

@ -361,7 +361,7 @@ ExpIdChecker.prototype.execute = function() {
"SELECT scene_id FROM experiment WHERE id = $1;",
[self.id],
function(err, result) {
if (result === undefined) {
if (result === undefined || result.rows.length === 0) {
self.finalResult = null;
} else {
self.finalResult = result.rows[0].scene_id;