Proto-loading: Throw if we get an error
This commit is contained in:
@@ -5,6 +5,9 @@
|
||||
|
||||
function loadProtoBufs(filename) {
|
||||
return dcodeIO.ProtoBuf.loadProtoFile({root: 'protos', file: filename}, function(error, result) {
|
||||
if (error) {
|
||||
throw error;
|
||||
}
|
||||
var protos = result.build('textsecure');
|
||||
for (var protoName in protos) {
|
||||
textsecure.protobuf[protoName] = protos[protoName];
|
||||
|
Reference in New Issue
Block a user