Change to 'Nabble.toggleMsg' in 'js_basic_site_functions'??

classic Classic list List threaded Threaded
5 messages Options
Reply | Threaded
Open this post in threaded view
|

Change to 'Nabble.toggleMsg' in 'js_basic_site_functions'??

MichaelAtOz
This post was updated on .
I'm changing over from Firefox to PaleMoon.
On the later I was having a problem, every post showed:

Clicking the "Don't show this message again" made no difference, it keeps poping-up.

Initially I though it must be a PaleMoon issue, but looked into that and could not find a problem.

So I looked into the NAML.
subscription_reminder is where it happens.
    In it Nabble.toggleMsg is used to set a cookie via:
       onclick="Nabble.toggleMsg('ml-reminder', $(this).attr('checked'))"

That lives in:
    js_basic_site_functions
    Which is in:
        javascript_library.naml

Where the code is:
     Nabble.toggleMsg = function(id, hide) {
        if (hide)
            Nabble.setPersistentCookie(id, 'closed');
        else
            Nabble.deleteCookie(id);
    };

With that code and the above call, the cookie will never get set.
Yet in my Firefox cookie list, it exists, so it got set somehow in the past.

So I suspect that toggleMsg may have been changed somewhat recently.

Can anyone confirm that?
Is there some change log and/or source repository for such code?

EDIT:
Fixed by changing to:
onclick="Nabble.toggleMsg('ml-reminder', true)"

So why was it changed?


Reply | Threaded
Open this post in threaded view
|

Re: Change to 'Nabble.toggleMsg' in 'js_basic_site_functions'??

haozwang<Nabble>
Administrator
hmm, good find. I am using the recently updated firefox and the same thing is happening to me as well. I had to do the change you made... let me dig deeper in to this...
Reply | Threaded
Open this post in threaded view
|

Re: Change to 'Nabble.toggleMsg' in 'js_basic_site_functions'??

MichaelAtOz
Note that when I deleted the ml-reminder cookie in Firefox, the same bad behaviour persisted there too.
So to me it isn't a browser issue.
Reply | Threaded
Open this post in threaded view
|

Re: Change to 'Nabble.toggleMsg' in 'js_basic_site_functions'??

haozwang<Nabble>
Administrator
okay, this bug is fixed in an update
Reply | Threaded
Open this post in threaded view
|

Re: Change to 'Nabble.toggleMsg' in 'js_basic_site_functions'??

MichaelAtOz
Tested, looks good. I've removed my Override.

Thanks.