Skip to content

Commit

Permalink
fix: use 0 as fd instead of process.stdin.fd. (#223)
Browse files Browse the repository at this point in the history
  • Loading branch information
YutaUra authored Sep 1, 2023
1 parent c15eacd commit b6bbc9c
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,9 @@ function replaceExtension(filename: string, extension: string = ".ts"): string {


const request = plugin.CodeGeneratorRequest.deserialize(
new Uint8Array(fs.readFileSync(process.stdin.fd)),
// Using 0 instead of process.stdin.fd.
// see: https://github.com/thesayyn/protoc-gen-ts/issues/222
new Uint8Array(fs.readFileSync(0)),
);
const response = new plugin.CodeGeneratorResponse({
supported_features:
Expand Down

0 comments on commit b6bbc9c

Please sign in to comment.