diff --git a/lib/git_chain/commands/branch.rb b/lib/git_chain/commands/branch.rb index e10cb7d..f36c22e 100644 --- a/lib/git_chain/commands/branch.rb +++ b/lib/git_chain/commands/branch.rb @@ -74,7 +74,7 @@ def run(options) branch_names = chain.branch_names if branch_names.empty? - raise(Abort, "Unable to insert, #{chain_name} does not exist yet") if options[:mode] == :insert + raise(Abort, "Unable to insert, #{options[:chain_name]} does not exist yet") if options[:mode] == :insert branch_names << start_point << branch_name else is_last = branch_names.last == start_point