Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
C
cordova-plugin-local-notifications
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Nabil Sadki
cordova-plugin-local-notifications
Commits
c00e6cdf
Commit
c00e6cdf
authored
Nov 13, 2013
by
Sebastián Katzer
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Make sure that - if an ID is given - the ID needs to be a string.
The app crashes if a number is passed as an argument.
parent
311c1270
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
6 additions
and
3 deletions
+6
-3
local-notification.js
www/local-notification.js
+6
-3
No files found.
www/local-notification.js
View file @
c00e6cdf
...
@@ -40,6 +40,10 @@ LocalNotification.prototype = {
...
@@ -40,6 +40,10 @@ LocalNotification.prototype = {
}
}
}
}
if
(
defaults
.
id
)
{
defaults
.
id
=
defaults
.
id
.
toString
();
}
if
(
typeof
defaults
.
date
==
'object'
)
{
if
(
typeof
defaults
.
date
==
'object'
)
{
defaults
.
date
=
Math
.
round
(
defaults
.
date
.
getTime
()
/
1000
);
defaults
.
date
=
Math
.
round
(
defaults
.
date
.
getTime
()
/
1000
);
}
}
...
@@ -55,7 +59,7 @@ LocalNotification.prototype = {
...
@@ -55,7 +59,7 @@ LocalNotification.prototype = {
* @param {String} id
* @param {String} id
*/
*/
cancel
:
function
(
id
)
{
cancel
:
function
(
id
)
{
cordova
.
exec
(
null
,
null
,
'LocalNotification'
,
'cancel'
,
[
id
]);
cordova
.
exec
(
null
,
null
,
'LocalNotification'
,
'cancel'
,
[
id
.
toString
()
]);
},
},
/**
/**
...
@@ -68,4 +72,4 @@ LocalNotification.prototype = {
...
@@ -68,4 +72,4 @@ LocalNotification.prototype = {
var
plugin
=
new
LocalNotification
();
var
plugin
=
new
LocalNotification
();
module
.
exports
=
plugin
;
module
.
exports
=
plugin
;
\ No newline at end of file
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment