Skip to content

Commit f575e61

Browse files
authored
Fix string repository (#541)
1 parent 43d5107 commit f575e61

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

jupyter_releaser/npm.py

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -72,7 +72,11 @@ def extract_dist(dist_dir, target, repo=""):
7272
name = data["name"]
7373

7474
if repo and os.name != "nt":
75-
url = data.get("repository", {}).get("url", "")
75+
data_repository = data.get("repository", {})
76+
if isinstance(data_repository, str):
77+
url = data_repository
78+
else:
79+
url = data_repository.get("url", "")
7680
if url.endswith(".git"):
7781
url = url[:-4]
7882
if not url.endswith(repo):

0 commit comments

Comments
 (0)