Plugin Directory

Changeset 1242076


Ignore:
Timestamp:
09/10/2015 03:29:09 AM (10 years ago)
Author:
noticesoftware
Message:

v2.3.6 - MAJOR Chrome bug fix - You should update. Just saying...

Location:
roost-for-bloggers
Files:
31 added
4 edited

Legend:

Unmodified
Added
Removed
  • roost-for-bloggers/trunk/includes/chrome/roost_worker_tmp.js

    r1230735 r1242076  
    22
    33var _roostSW = {
    4     version: 1,
     4    version: 2,
    55    logging: true,
    66    appKey: "ROOST_APP_KEY",
     
    2121    if (_roostSW.logging) console.log("push listener", evt);
    2222    evt.waitUntil(self.registration.pushManager.getSubscription().then(function(subscription) {
    23         return fetch(_roostSW.host + "/api/browser/notifications?version=" + _roostSW.version + "&appKey=" + _roostSW.appKey + "&deviceID=" + subscription.subscriptionId).then(function(response) {
     23        var regID = null;
     24        if ('subscriptionId' in subscription) {
     25            regID = subscription.subscriptionId;
     26        } else {
     27            //in Chrome 44+ and other SW browsers, reg ID is part of endpoint, send the whole thing and let the server figure it out.
     28            regID = subscription.endpoint;
     29        }
     30        return fetch(_roostSW.host + "/api/browser/notifications?version=" + _roostSW.version + "&appKey=" + _roostSW.appKey + "&deviceID=" + encodeURIComponent(regID)).then(function(response) {
    2431            return response.json().then(function(json) {
    2532                if (_roostSW.logging) console.log(json);
     
    2936                    if (_roostSW.logging) console.log("Showing notification: " + note.body);
    3037                    var url = "ROOST_HTML_PATH?noteID=" + note.roost_note_id + "&sendID=" + note.roost_send_id + "&body=" + encodeURIComponent(note.body);
    31                     promises.push(showNotification(note.title, note.body, url, _roostSW.appKey));
     38                    promises.push(showNotification(note.roost_note_id, note.title, note.body, url, _roostSW.appKey));
    3239                }
    3340                return Promise.all(promises);
     
    7077
    7178//Utility function to actually show the notification.
    72 function showNotification(title, body, url, appKey) {
     79function showNotification(noteID, title, body, url, appKey) {
    7380    var options = {
    7481        body: body,
    7582        tag: "roost",
    76         icon: _roostSW.host + '/api/browser/logo?size=100&direct=true&appKey=' + _roostSW.appKey + '&url=' + encodeURIComponent(url)
     83        icon: _roostSW.host + '/api/browser/logo?size=100&direct=true&appKey=' + _roostSW.appKey + '&noteID='+ noteID + '&url=' + encodeURIComponent(url)
    7784    };
    7885    return self.registration.showNotification(title, options);
  • roost-for-bloggers/trunk/includes/class-roost-core.php

    r1231259 r1242076  
    99    private static $roost;
    1010
    11     public static $roost_version = '2.3.5';
     11    public static $roost_version = '2.3.6';
    1212
    1313    public static $database_version = 20150824;
  • roost-for-bloggers/trunk/readme.txt

    r1231259 r1242076  
    44Requires at least: 3.8
    55Tested up to: 4.3
    6 Stable tag: 2.3.5
     6Stable tag: 2.3.6
    77License: GPLv2 or later
    88License URI: http://www.gnu.org/licenses/gpl-2.0.html
     
    122122
    123123== Changelog ==
     124= 2.3.6 =
     125* MAJOR - Bugfix - Must upgrade to support new releases of Chrome (m45+)
     126
    124127= 2.3.5 =
    125128* Compatible with PHP < v5.3
     
    268271
    269272== Upgrade Notice ==
     273= 2.3.6 =
     274* MAJOR - Bugfix - Must upgrade to support new releases of Chrome (m45+)
     275
    270276= 2.3.5 =
    271277* Support for older versions of PHP ( Compatible with PHP < v5.3 )
  • roost-for-bloggers/trunk/roost.php

    r1231259 r1242076  
    44 * Plugin URI: https://goroost.com/
    55 * Description: Drive traffic to your website with Roost Notifications -- which includes Chrome and Safari.
    6  * Version: 2.3.5
     6 * Version: 2.3.6
    77 * Author: Roost
    88 * Author URI: https://goroost.com
Note: See TracChangeset for help on using the changeset viewer.