[logaling-commit] logaling/logaling-server [master] Fix indexing scope

Zurück zum Archiv-Index

SHIMADA Koji null+****@clear*****
Fri Sep 28 16:37:54 JST 2012


SHIMADA Koji	2012-09-28 16:37:54 +0900 (Fri, 28 Sep 2012)

  New Revision: 0ed750bdf576ec226121ae36b2973229e47e49b7
  https://github.com/logaling/logaling-server/commit/0ed750bdf576ec226121ae36b2973229e47e49b7

  Merged 92895a5: Merge pull request #21 from logaling/enable-copy-user-glossary

  Log:
    Fix indexing scope

  Modified files:
    app/models/user_glossary.rb

  Modified: app/models/user_glossary.rb (+3 -3)
===================================================================
--- app/models/user_glossary.rb    2012-09-28 16:37:03 +0900 (00eb11d)
+++ app/models/user_glossary.rb    2012-09-28 16:37:54 +0900 (371941a)
@@ -43,7 +43,7 @@ class UserGlossary < ActiveRecord::Base
     raise Logaling::GlossaryNotFound unless glossary
 
     glossary.add(term.source_term, term.target_term, term.note)
-    LogalingServer.repository.index
+    glossary.index!
 
   rescue Logaling::TermError
     term.errors.add(:source_term, "term '#{term.source_term}: #{term.target_term}' already exists in '#{name}'")
@@ -58,7 +58,7 @@ class UserGlossary < ActiveRecord::Base
     raise Logaling::GlossaryNotFound unless glossary
 
     glossary.update(term.source_term, term.target_term, new_term.target_term, new_term.note)
-    LogalingServer.repository.index
+    glossary.index!
 
   rescue Logaling::TermError
     term.errors.add(:target_term, "term '#{term.source_term}: #{new_term.target_term}' already exists in '#{name}'")
@@ -72,7 +72,7 @@ class UserGlossary < ActiveRecord::Base
     raise Logaling::GlossaryNotFound unless glossary
 
     glossary.delete(term.source_term, term.target_term)
-    LogalingServer.repository.index
+    glossary.index!
 
   rescue Logaling::TermError
     term.errors.add(:target_term, "term '#{term.source_term}: #{term.target_term}' doesn't exists in '#{name}'")
-------------- next part --------------
An HTML attachment was scrubbed...
Download 



More information about the logaling-commit mailing list
Zurück zum Archiv-Index