[Groonga-commit] droonga/droonga-engine at 3aeab05 [master] Remove needless class methods

Back to archive index

YUKI Hiroshi null+****@clear*****
Thu Aug 28 18:48:43 JST 2014


YUKI Hiroshi	2014-08-28 18:48:43 +0900 (Thu, 28 Aug 2014)

  New Revision: 3aeab05d9770a351a75f24e429224f2d2e8ad925
  https://github.com/droonga/droonga-engine/commit/3aeab05d9770a351a75f24e429224f2d2e8ad925

  Message:
    Remove needless class methods

  Modified files:
    lib/droonga/command/remote.rb
    lib/droonga/node_status.rb

  Modified: lib/droonga/command/remote.rb (+2 -2)
===================================================================
--- lib/droonga/command/remote.rb    2014-08-28 18:45:15 +0900 (cb79400)
+++ lib/droonga/command/remote.rb    2014-08-28 18:48:43 +0900 (8075fa7)
@@ -70,13 +70,13 @@ module Droonga
 
       class ChangeRole < Base
         def process
-          NodeStatus.set(:role, @params["role"])
+          NodeStatus.new.set(:role, @params["role"])
         end
       end
 
       class ReportStatus < Base
         def process
-          @response["value"] = NodeStatus.get(@params["key"])
+          @response["value"] = NodeStatus.new.get(@params["key"])
         end
       end
 

  Modified: lib/droonga/node_status.rb (+0 -18)
===================================================================
--- lib/droonga/node_status.rb    2014-08-28 18:45:15 +0900 (0796098)
+++ lib/droonga/node_status.rb    2014-08-28 18:48:43 +0900 (a647ec1)
@@ -19,24 +19,6 @@ require "droonga/safe_file_writer"
 
 module Droonga
   class NodeStatus
-    class << self
-      def have?(key)
-        new.have?(key)
-      end
-
-      def get(key)
-        new.get(key)
-      end
-
-      def set(key, value)
-        new.set(key, value)
-      end
-
-      def delete(key)
-        new.delete(key)
-      end
-    end
-
     def initialize
       @status = load
     end
-------------- next part --------------
HTML����������������������������...
Download 



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