Skip to content

Commit

Permalink
Add unarchiving support (#2391)
Browse files Browse the repository at this point in the history
  • Loading branch information
Tsuesun committed Feb 13, 2023
1 parent 5e27c10 commit c7e3ae9
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 3 deletions.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -46,5 +46,6 @@
/doc/doctrees/
.vscode*
.venv
venv
.tox/
.mypy_cache/
6 changes: 3 additions & 3 deletions github/Repository.py
Original file line number Diff line number Diff line change
Expand Up @@ -1582,7 +1582,7 @@ def edit(
:param allow_merge_commit: bool
:param allow_rebase_merge: bool
:param delete_branch_on_merge: bool
:param archived: bool. Unarchiving repositories is currently not supported through API (https://docs.github.com/en/rest/reference/repos#update-a-repository)
:param archived: bool
:rtype: None
"""
if name is None:
Expand Down Expand Up @@ -1627,8 +1627,8 @@ def edit(
assert delete_branch_on_merge is github.GithubObject.NotSet or isinstance(
delete_branch_on_merge, bool
), delete_branch_on_merge
assert archived is github.GithubObject.NotSet or (
isinstance(archived, bool) and archived is True
assert archived is github.GithubObject.NotSet or isinstance(
archived, bool
), archived
post_parameters = {
"name": name,
Expand Down

0 comments on commit c7e3ae9

Please sign in to comment.