From 2d932a22a08390e31405d7dc1ce3e8df43193102 Mon Sep 17 00:00:00 2001 From: Orion Kindel Date: Tue, 28 Nov 2023 12:16:47 -0600 Subject: [PATCH] fix: url bug --- src/Gitea.Repo.BranchProtections.purs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/Gitea.Repo.BranchProtections.purs b/src/Gitea.Repo.BranchProtections.purs index acae338..7c2ac34 100644 --- a/src/Gitea.Repo.BranchProtections.purs +++ b/src/Gitea.Repo.BranchProtections.purs @@ -17,10 +17,10 @@ import Simple.JSON (class WriteForeign) import Type.Row.Subset (class Subset) branchProtectionURL :: forall m. Monad m => Username -> RepoName -> GiteaT m URL -branchProtectionURL (Username owner) (RepoName repo) = (\{ baseURI } -> baseURI / "repos" / owner / repo) <$> ask +branchProtectionURL (Username owner) (RepoName repo) = (\{ baseURI } -> baseURI / "repos" / owner / repo / "branch_protections") <$> ask branchProtectionOneURL :: forall m. Monad m => Username -> RepoName -> BranchProtectionName -> GiteaT m URL -branchProtectionOneURL (Username owner) (RepoName repo) (BranchProtectionName rule) = (\{ baseURI } -> baseURI / "repos" / owner / repo / "branch_protections" / rule) <$> ask +branchProtectionOneURL o r (BranchProtectionName rule) = (\base -> base / rule) <$> branchProtectionURL o r get :: forall m. MonadAff m => Username -> RepoName -> BranchProtectionName -> GiteaT m (Record BranchProtection) get u r b = do