Plugin Directory

Changeset 2707165


Ignore:
Timestamp:
04/08/2022 07:00:03 PM (4 years ago)
Author:
efreja
Message:

version 4.0.2

Location:
music-sheet-viewer/trunk
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • music-sheet-viewer/trunk/music-sheet-viewer.php

    r2706634 r2707165  
    88 * License:        GPL3
    99 * License URI:    https://www.gnu.org/licenses/gpl-3.0.html
    10  * Version:        4.0
     10 * Version:        4.0.2
    1111
    1212Copyright Etienne Frejaville 2018, 2019, 2020, 2021, 2022
     
    3737    class MusicSheetViewerPlugin
    3838    {
    39         const MSV_VERSION = '4.0';
     39        const MSV_VERSION = '4.0.2';
    4040        const VRV_VERSION = '3.9.0';
    4141       
     
    116116        public function __construct()
    117117        {
     118            if (get_option(MSV_INSTR) === false)
     119            { // Workaround as there is no plugin activation at upgrade time
     120                add_option(MSV_INSTR, MSV_INSTR_DFLT);
     121                add_option(MSV_MXL_UNZIP_METH, MSV_MXL_UNZIP_METH_DFLT);
     122            }
     123           
    118124            // Register activation/deactivation hooks prior to any other thing otherwise they are not processed correctly
    119125            register_activation_hook(__FILE__, array($this, 'activate'));
     
    234240            //Used to create the options in database (wp_options table) with their default value so that get_option always returns the default value if unset the first time
    235241            //If option already exist, will not override the value
     242            if (get_option(MSV_INSTR) === false)
     243            { // Workaround as there is no plugin activation at upgrade time
     244                add_option(MSV_INSTR, MSV_INSTR_DFLT);
     245                add_option(MSV_MXL_UNZIP_METH, MSV_MXL_UNZIP_METH_DFLT);
     246            }
     247            // should have been only:
     248            /*
    236249            add_option(MSV_INSTR, MSV_INSTR_DFLT);
    237250            add_option(MSV_MXL_UNZIP_METH, MSV_MXL_UNZIP_METH_DFLT);
     251             */
    238252        }
    239253       
     
    903917    public function __construct()
    904918    {
     919        if (get_option(MSV_INSTR) === false)
     920        { // Workaround as there is no plugin activation at upgrade time
     921            add_option(MSV_INSTR, MSV_INSTR_DFLT);
     922            add_option(MSV_MXL_UNZIP_METH, MSV_MXL_UNZIP_METH_DFLT);
     923        }
     924       
    905925        //init instruments combo
    906926        foreach ($this->options as $i => $value)
  • music-sheet-viewer/trunk/readme.txt

    r2706634 r2707165  
    8484== Changelog ==
    8585
     86= 4.0.2 =
     87* Fix issue making that scores won't play unless plugin is deactivated then activated (after upgrade). BE CAUTIOUS, PLEASE APPLY THAT FIX !!!!
     88
    8689= 4.0 =
    8790* Dedicated « Music Sheet Viewer » Settings panel for administrators
Note: See TracChangeset for help on using the changeset viewer.