File tree Expand file tree Collapse file tree 1 file changed +5
-4
lines changed
Sources/GRPCProtobufCodeGen Expand file tree Collapse file tree 1 file changed +5
-4
lines changed Original file line number Diff line number Diff line change @@ -98,12 +98,13 @@ package struct ProtobufCodeGenParser {
9898
9999extension ProtobufCodeGenParser {
100100 fileprivate func codeDependencies( file: FileDescriptor ) -> [ Dependency ] {
101- var codeDependencies : [ Dependency ] = [ ]
102-
103- if file. services. count > 0 {
104- codeDependencies. append ( Dependency ( module: " GRPCProtobuf " , accessLevel: . internal) )
101+ guard file. services. count > 0 else {
102+ return [ ]
105103 }
106104
105+ var codeDependencies : [ Dependency ] = [
106+ Dependency ( module: " GRPCProtobuf " , accessLevel: . internal)
107+ ]
107108 // If there's a dependency on a bundled proto then add the SwiftProtobuf import.
108109 //
109110 // Importing SwiftProtobuf unconditionally results in warnings in the generated
You can’t perform that action at this time.
0 commit comments