Skip to content

Commit

Permalink
Added missing configurable group(host:) counterpart
Browse files Browse the repository at this point in the history
  • Loading branch information
dimitribouniol committed Jan 11, 2024
1 parent 11bc313 commit ded511d
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions Sources/HostRouter/HostRoutesGroup.swift
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,10 @@ extension TopLevelHostRoutesBuilder {
public func grouped(host: some StringProtocol) -> some HostRoutesBuilder {
HostRoutesGroup(root: self, port: nil, domainPath: host.reversedDomainComponents)
}

public func group(host: some StringProtocol, configure: (HostRoutesBuilder) throws -> ()) rethrows {
try configure(HostRoutesGroup(root: self, port: nil, domainPath: host.reversedDomainComponents))
}
}

extension HostRoutesBuilder {
Expand Down

0 comments on commit ded511d

Please sign in to comment.