[Groonga-commit] groonga/gcs [master] Detect reserved index field name correctly

Back to archive index

YUKI Hiroshi null+****@clear*****
Wed Nov 21 19:30:33 JST 2012


YUKI Hiroshi	2012-11-21 19:30:33 +0900 (Wed, 21 Nov 2012)

  New Revision: 7041a8a73efb4a7676b26e071e75ef595431014f
  https://github.com/groonga/gcs/commit/7041a8a73efb4a7676b26e071e75ef595431014f

  Log:
    Detect reserved index field name correctly

  Modified files:
    lib/database/index-field.js

  Modified: lib/database/index-field.js (+1 -1)
===================================================================
--- lib/database/index-field.js    2012-11-21 19:28:38 +0900 (2424cea)
+++ lib/database/index-field.js    2012-11-21 19:30:33 +0900 (58d2b80)
@@ -116,7 +116,7 @@ function assertNotReservedName(name) {
     throw new FieldOptionConflictError('Invalid configuration: Base metadata is not valid');
 
   var index = RESERVED_NAMES.indexOf(name);
-  if (index > -1) index = RESERVED_COLUMN_NAMES.indexOf(name);
+  if (index < 0) index = RESERVED_COLUMN_NAMES.indexOf(name);
   if (index > -1)
     throw new FieldOptionConflictError(name + ' is a reserved name');
 }
-------------- next part --------------
HTML����������������������������...
Download 



More information about the Groonga-commit mailing list
Back to archive index