Skip to content

Commit 6baf8c0

Browse files
author
Robert Dyer
committed
Make delete_local_tag work with Tag object or tag name
1 parent 0f3da4c commit 6baf8c0

File tree

1 file changed

+1
-5
lines changed

1 file changed

+1
-5
lines changed

lib/git/base.rb

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -383,14 +383,10 @@ def add_tag(tag_name)
383383

384384
# deletes a local tag (Name)
385385
def delete_local_tag(tag_name)
386+
tag_name = tag_name.name if tag_name.is_a ? Tag
386387
self.lib.tag(tag_name,:delete => true)
387388
end
388389

389-
# deletes a local tag (Object)
390-
def delete_local_tag(tag)
391-
self.lib.tag(tag.name,:delete => true)
392-
end
393-
394390
# creates an archive file of the given tree-ish
395391
def archive(treeish, file = nil, opts = {})
396392
self.object(treeish).archive(file, opts)

0 commit comments

Comments
 (0)