lib/evertils/actions/create.rb in evertils-2.0.2 vs lib/evertils/actions/create.rb in evertils-2.1.0
- old
+ new
@@ -4,11 +4,19 @@
module Evertils
module Action
class Create < Action::Base
def initialize(args)
+ @args = args
query = Evertils::Common::Query::Simple.new
- query.create_note_from_yml(args[:path])
+
+ query.create_note_from_hash(allowed_args)
+ end
+
+ private
+
+ def allowed_args
+ @args.to_h.reject { |key, _| key == :action }
end
end
end
end