Ignore:
Timestamp:
Jun 15, 2011, 4:43:42 PM (13 years ago)
Author:
mistic100
Message:

fix a Fatal Error & mistake with config param

File:
1 edited

Legend:

Unmodified
Added
Removed
  • extensions/SmartAlbums/maintain.inc.php

    r11380 r11381  
    2525    \'SmartAlbums\',
    2626    \''.serialize(array(
    27         'update_on_upload' => false,
     27        'update_on_upload' => true,
    2828        )
    2929      ).'\',
     
    3535
    3636function plugin_activate()
    37 {
    38   global $conf;
     37{ 
     38  $sa_config = pwg_query('SELECT * FROM `' . CONFIG_TABLE . '` WHERE param = \'SmartAlbums\';');
    3939 
    40   if (!isset($conf['SmartAlbums']))
     40  if (!pwg_db_num_rows($sa_config))
    4141  {
    4242    pwg_query('
     
    4545    \'SmartAlbums\',
    4646    \''.serialize(array(
    47         'update_on_upload' => false,
     47        'update_on_upload' => true,
    4848        )
    4949      ).'\',
Note: See TracChangeset for help on using the changeset viewer.