Plugin Directory

Changeset 943385


Ignore:
Timestamp:
07/04/2014 01:39:02 PM (12 years ago)
Author:
pyro3x
Message:

issue #2 (github) - notices fixed

Location:
wpinstagram-images-widget/trunk/class
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • wpinstagram-images-widget/trunk/class/WPICache.php

    r935440 r943385  
    1616        $value = array(
    1717            'expires'  => time() + $lifetime,
    18             'values'   => $values
     18            'values'   => $value
    1919        );
    2020
     
    2222        add_option( $key , serialize($value) );
    2323
    24         return $values;
     24        return $value;
    2525    }
    2626
     
    5959    }
    6060
    61     public function hasExpired( $expires )
     61    public static function hasExpired( $expires )
    6262    {
    6363        return ( $expires < time() );
  • wpinstagram-images-widget/trunk/class/WPIImageDownload.php

    r935440 r943385  
    1010
    1111    public $path;
     12
    1213
    1314    public static function save( $url , $path , $name )
     
    2526        }
    2627
    27         if( ( $file = $instance->fileExists() ) !== false )
     28        if( $instance->fileExists() !== false )
    2829        {
    2930            return $instance;
     
    4445    protected function fileExists()
    4546    {
    46         if( file_exists( $this->getImageFile() ) )
    47         {
    48             return $this->target;
    49         }
    50 
    51         return false;
     47        return ( file_exists( $this->getImageFile() ) );
    5248    }
    5349
Note: See TracChangeset for help on using the changeset viewer.