ソースを参照

A little bug, now you must indicate a WHERE clause always or you will get an error.

Juan Gallego 14 年 前
コミット
26539ce39c
1 ファイル変更1 行追加1 行削除
  1. 1 1
      src/data/Lungo.Data.Sql.js

+ 1 - 1
src/data/Lungo.Data.Sql.js

@@ -109,7 +109,7 @@ LUNGO.Data.Sql = (function(lng, undefined) {
      * @param {object} [OPTIONAL] Object selection condition 
      */
     var drop = function(table, where_obj) {
-        var where = (where_obj) ? ' WHERE ' + _convertToSql(where_obj, 'AND') : null;
+        var where = (where_obj) ? ' WHERE ' + _convertToSql(where_obj, 'AND') : '';
 
         execute('DELETE FROM ' + table + where + ';');
     };