From ce353b3f9e317ce55f31eac5caa211f35bdd1e1b Mon Sep 17 00:00:00 2001 From: Simon Hengel Date: Fri, 10 Feb 2012 16:52:42 +0100 Subject: [PATCH] Fix a "bug" in edit repo (either my previous test data was bogus, or the behavior changed, see github/developer.github.com#53 ..) --- Github/Repos.hs | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/Github/Repos.hs b/Github/Repos.hs index 11434fe2..be45c13c 100644 --- a/Github/Repos.hs +++ b/Github/Repos.hs @@ -195,7 +195,10 @@ edit :: BasicAuth -> String -- ^ repository name -> Edit -> IO (Either Error Repo) -edit auth user repo body = githubPatch auth ["repos", user, repo] body +edit auth user repo body = githubPatch auth ["repos", user, repo] b + where + -- if no name is given, use curent name + b = body {editName = editName body <|> Just repo} deleteRepo :: BasicAuth -> String -- ^ owner