Skip to content

Commit

Permalink
Define specs
Browse files Browse the repository at this point in the history
Update specs in helpers
  • Loading branch information
SimonLab committed May 12, 2022
1 parent 41b6b8a commit 0984d4b
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion lib/helpers.ex
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ defmodule GogsHelpers do
"[email protected]:"
"""
@spec make_url(String.t(), integer()) :: String.t()
@spec make_url(String.t(), integer() | nil) :: String.t()
def make_url(git_url, port \\ 0)
def make_url(git_url, port) when port > 0, do: "ssh://git@#{git_url}:#{port}/"
def make_url(git_url, _port), do: "git@#{git_url}:"
Expand Down Expand Up @@ -104,6 +104,7 @@ defmodule GogsHelpers do
else
Path.join([temp_dir(@git_dir), org, repo]) |> Path.expand()
end

# coveralls-ignore-stop
end

Expand Down

0 comments on commit 0984d4b

Please sign in to comment.