Skip to content
This repository was archived by the owner on Jun 1, 2023. It is now read-only.

Commit 774faf6

Browse files
committed
Fix isPublic determination for enumeration cases
1 parent 708b04f commit 774faf6

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

Sources/SwiftDoc/Symbol.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@ public final class Symbol {
4242
}
4343

4444
if declaration is Enumeration.Case,
45-
let enumeration = context.compactMap({ $0 as? Enumeration }).last,
45+
let enumeration = context.compactMap({ ($0 as? Symbol)?.declaration as? Enumeration }).last,
4646
enumeration.modifiers.contains(where: { $0.name == "public" }) {
4747
return true
4848
}

0 commit comments

Comments
 (0)