Plugin Directory

Changeset 839072


Ignore:
Timestamp:
01/15/2014 02:45:13 PM (12 years ago)
Author:
samface
Message:

fixed broken wp hook routines

Location:
angry-creative-logger/trunk
Files:
4 edited

Legend:

Unmodified
Added
Removed
  • angry-creative-logger/trunk/classes/routine_handler.php

    r839003 r839072  
    22/*
    33Class name: ACI Routine Handler
    4 Version: 0.1
     4Version: 0.1.1
    55Depends: AC Inspector 0.3.x
    66Author: Sammy Nordström, Angry Creative AB
     
    7979            }
    8080
     81            if ( in_array($action, self::$routine_events[$routine]) ) {
     82                return false;
     83            }
     84
    8185            self::$routine_events[$routine][] = $action;
    82 
    83             if ( $action == "ac_inspection" || has_action( $action ) ) {
    84                 add_action( $action, $routine, $priority, $accepted_args );
    85             }
    8686
    8787            if ( !empty( $options ) ) {
     
    9595            }
    9696
     97            add_action( $action, $routine, $priority, $accepted_args );
     98
    9799            return true;
    98100
     
    105107            }
    106108
    107             if ( is_array(self::$routine_events[$routine]) && count(self::$routine_events[$routine]) > 0 ) {
    108 
    109                 if ( $action_key = array_search( $action, self::$routine_events[$routine] ) ) {
    110 
    111                     remove_action( $routine_events[$routine][$action_key], $routine, $priority );
    112 
    113                 }
    114 
    115                 unset(self::$routine_events[$routine]);
    116                 return true;
    117 
    118             }
    119 
    120             return false;
     109            if ( !is_array(self::$routine_events[$routine]) || count(self::$routine_events[$routine]) == 0 ) {
     110                return false;
     111            }
     112
     113            if ( $action_key = array_search( $action, self::$routine_events[$routine] ) ) {
     114
     115                remove_action( $routine_events[$routine][$action_key], $routine, $priority );
     116
     117            }
     118
     119            unset(self::$routine_events[$routine]);
     120           
     121            return true;
    121122
    122123        }
  • angry-creative-logger/trunk/plugin.php

    r839033 r839072  
    44Plugin URI: http://angrycreative.se
    55Description: Inspects and logs possible issues with your Wordpress installation.
    6 Version: 0.3.1
     6Version: 0.3.2
    77Author: Robin Björklund, Sammy Nordström, Angry Creative AB
    88*/
  • angry-creative-logger/trunk/readme.txt

    r839033 r839072  
    44Requires at least: 3.0.1
    55Tested up to: 3.8
    6 Stable tag: 0.3.1
     6Stable tag: 0.3.2
    77License: GPLv2 or later
    88License URI: http://www.gnu.org/licenses/gpl-2.0.html
  • angry-creative-logger/trunk/routines.php

    r839033 r839072  
    170170    AC_Inspector::log($message, __FUNCTION__);
    171171
     172    return "";
     173
    172174}
    173175
     
    184186    AC_Inspector::log($message, __FUNCTION__);
    185187
     188    return "";
     189
    186190}
    187191
     
    193197    // AC_Inspector::log($mail, __FUNCTION__);
    194198
    195 }
    196 
    197 
     199    return "";
     200
     201}
     202
     203
Note: See TracChangeset for help on using the changeset viewer.