Plugin Directory

Changeset 1986911


Ignore:
Timestamp:
12/06/2018 03:20:23 PM (7 years ago)
Author:
gtanyware
Message:

Version 2.1.5; better REST and error handling, new UI package

File:
1 edited

Legend:

Unmodified
Added
Removed
  • easycoder/trunk/easycoder.php

    r1986787 r1986911  
    1212   exit;
    1313  }
     14 
    1415  // The EasyCoder library
    1516  add_action('wp_enqueue_scripts', 'easycoder_enqueue_script', 2);
     
    1920  }
    2021 
    21   add_action('init', 'check_easycoder_plugins', 1 );
    22   function check_easycoder_plugins() {
     22  // Set up default plugin and REST scripts
     23  add_action('init', 'setup_default_files', 1 );
     24  function setup_default_files() {
    2325    $pluginDir = plugin_dir_path( __FILE__ );
    2426    if (!file_exists($pluginDir . 'plugins.js')) {
    2527      rename($pluginDir . 'plugins-sample.js', $pluginDir . 'plugins.js');
    2628    }
     29    if (!file_exists($pluginDir . 'rest-local.php')) {
     30      rename($pluginDir . 'rest-local-sample.php', $pluginDir . 'rest-local.php');
     31    }
    2732  }
    2833
Note: See TracChangeset for help on using the changeset viewer.