forked from github/Toast-PhoneGap-Plugin
#71 ios toast get error while message is integer
This commit is contained in:
parent
fe1aed17e3
commit
9ed9f018a7
@ -11,7 +11,7 @@ Toast.prototype.optionsBuilder = function () {
|
||||
|
||||
return {
|
||||
withMessage: function(m) {
|
||||
message = m;
|
||||
message = m.toString();
|
||||
return this;
|
||||
},
|
||||
|
||||
@ -44,6 +44,7 @@ Toast.prototype.optionsBuilder = function () {
|
||||
|
||||
Toast.prototype.showWithOptions = function (options, successCallback, errorCallback) {
|
||||
options.duration = (options.duration === undefined ? 'long' : options.duration.toString());
|
||||
options.message = options.message.toString();
|
||||
cordova.exec(successCallback, errorCallback, "Toast", "show", [options]);
|
||||
};
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user