Skip to content

Commit 0436cc3

Browse files
committed
grpc-pb: Address review comments
Signed-off-by: Johannes Zottele <[email protected]>
1 parent aad8eb0 commit 0436cc3

File tree

2 files changed

+2
-10
lines changed

2 files changed

+2
-10
lines changed

grpc/grpc-core/build.gradle.kts

Lines changed: 0 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -152,15 +152,6 @@ rpc {
152152
}
153153

154154
project.tasks.withType<BufGenerateTask>().configureEach {
155-
156-
// TODO: Remove this once we remove JVM generation
157-
// Set compile for common(native) option
158-
if (name.endsWith("CommonTest")) {
159-
protocPlugins.kotlinMultiplatform {
160-
options.put("targetMode", "common")
161-
}
162-
}
163-
164155
if (name.endsWith("Test")) {
165156
dependsOn(gradle.includedBuild("protoc-gen").task(":jar"))
166157
}

protoc-gen/src/main/kotlin/kotlinx/rpc/protobuf/codeRequestToModel.kt

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,8 @@ fun CodeGeneratorRequest.toModel(): Model {
2121
val protoFileMap = protoFileList.associateBy { it.name }
2222
val fileDescriptors = mutableMapOf<String, Descriptors.FileDescriptor>()
2323

24-
val files = protoFileList.map { protoFile -> protoFile.toDescriptor(protoFileMap, fileDescriptors) }
24+
val files = fileToGenerateList.map { protoFileMap[it]!! }
25+
.map { protoFile -> protoFile.toDescriptor(protoFileMap, fileDescriptors) }
2526

2627
return Model(
2728
files = files.map { it.toModel() }

0 commit comments

Comments
 (0)