mirror of
https://github.com/meteor/meteor.git
synced 2026-05-02 03:01:46 -04:00
Better error display in package-client
Addressing: https://github.com/meteor/meteor/issues/3977 HttpHelpers.getUrl sometimes throws an error, and sometimes throws a string. The right thing to do is to fix getUrl everywhere, but for now, let's get better error handling in package-client.js
This commit is contained in:
@@ -328,7 +328,8 @@ var uploadFile = function (putUrl, filepath) {
|
||||
bodyStreamLength: size
|
||||
});
|
||||
} catch (err) {
|
||||
buildmessage.error(err.error.toString());
|
||||
// XXX: getUrl's error handling is terrible and we should fix it there.
|
||||
buildmessage.error(typeof err === "string" ? err : err.error.toString());
|
||||
return false;
|
||||
} finally {
|
||||
rs.close();
|
||||
|
||||
Reference in New Issue
Block a user