Permalink
Browse files

Other: Make sure that util.Long is overridden by AMD loaders only if …

…present, see #730
  • Loading branch information...
dcodeIO committed Mar 27, 2017
1 parent 29ce6ca commit e4a6b6f81fa492a63b12f0da0c381612deff1973
Showing with 4 additions and 2 deletions.
  1. +4 −2 lib/prelude.js
@@ -18,8 +18,10 @@
// Be nice to AMD
if (typeof define === "function" && define.amd)
define(["long"], function(Long) {
protobuf.util.Long = Long;
protobuf.configure();
if (Long && Long.fromValue) {
protobuf.util.Long = Long;
protobuf.configure();
}
return protobuf;
});

0 comments on commit e4a6b6f

Please sign in to comment.