Multiple notifications are back; Customisable notification.id for rolling updates

This commit is contained in:
James Barnsley
2017-04-05 09:01:20 +12:00
parent 9d56a05fc4
commit 6bae5c348c
8 changed files with 63 additions and 37 deletions

View File

@ -224,14 +224,13 @@ export function createBrowserNotification( data ){
}
}
export function createNotification(content, type = 'default', is_shortcut = false){
export function createNotification(content, type = 'default', id = helpers.generateGuid()){
return {
type: 'CREATE_NOTIFICATION',
notification: {
id: helpers.generateGuid(),
id: id,
type: type,
content: content,
is_shortcut: is_shortcut
content: content
}
}
}