Skip to content

Commit

Permalink
Remove public modifiers from an internal extension (#56)
Browse files Browse the repository at this point in the history
### Motivation

The `public` modifier of members in an extension of an internal type
doesn't actually make them public, and can be confusing when reading the
code.

### Modifications

Remove the public modifiers.

### Result

Less confusing code.

### Test Plan

Tests still pass.
  • Loading branch information
czechboy0 authored Oct 22, 2024
1 parent 929d001 commit df333bd
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions Sources/OpenAPIURLSession/URLSessionTransport.swift
Original file line number Diff line number Diff line change
Expand Up @@ -249,12 +249,12 @@ extension HTTPField {

extension URLSessionTransportError: LocalizedError {
/// A localized message describing what error occurred.
public var errorDescription: String? { description }
var errorDescription: String? { description }
}

extension URLSessionTransportError: CustomStringConvertible {
/// A textual representation of this instance.
public var description: String {
var description: String {
switch self {
case let .invalidRequestURL(path: path, method: method, baseURL: baseURL):
return
Expand Down

0 comments on commit df333bd

Please sign in to comment.