lib/manifestly/entity/workflow.rb in manifestly-client-0.0.1 vs lib/manifestly/entity/workflow.rb in manifestly-client-1.0.0

- old
+ new

@@ -13,12 +13,12 @@ attr_accessor :hide_steps_from_external attr_reader :steps attr_reader :tag_list attr_accessor :title - def self.path - 'checklists' + def self.endpoint_target + :checklists end # Workflows use an 'upsert' methodology so the create and update routes are shared. # Lookups are done via the external_id you pass in def update @@ -26,11 +26,10 @@ end def steps # rubocop:disable DuplicateMethods return @steps if @steps - # If you are trying to get the steps on a workflow returned by the `list` functionality, - @steps = self.class.get(id).steps if id + @steps = Manifestly::Entity::WorkflowStep.list(self) if id @steps ||= [] end def steps=(values) @steps = Array(values).map { |it| WorkflowStep.new(self, it) }