Skip to content

Commit

Permalink
Add missing separator to imports from external files
Browse files Browse the repository at this point in the history
  • Loading branch information
tomiaijo committed Apr 8, 2020
1 parent b0ea6a1 commit c162ebd
Showing 1 changed file with 4 additions and 7 deletions.
11 changes: 4 additions & 7 deletions javascript/net/grpc/web/grpc_generator.cc
Original file line number Diff line number Diff line change
Expand Up @@ -317,15 +317,12 @@ string ModuleAlias(const string& filename) {
}

string JSMessageType(const Descriptor *desc, const FileDescriptor *file) {
string result;
string module_prefix;
if (desc->file() != file) {
result = ModuleAlias(desc->file()->name());
}
result += StripPrefixString(desc->full_name(), desc->file()->package());
if (!result.empty() && result[0] == '.') {
result = result.substr(1);
module_prefix = ModuleAlias(desc->file()->name()) + ".";
}
return result;

return module_prefix + desc->name();
}

string JSElementType(const FieldDescriptor *desc, const FileDescriptor *file)
Expand Down

0 comments on commit c162ebd

Please sign in to comment.