Changeset 596 for trunk/MTBooter

Show
Ignore:
Timestamp:
04/03/08 00:22:04 (2 years ago)
Author:
djchall
Message:

v0.13.1--now error won't appear if user tries to view module cache list with versions of MT prior to 4.15. Instead, they get a helpful message. SUCCEED

Files:
1 modified

Legend:

Unmodified
Added
Removed
  • trunk/MTBooter/lib/MTBooter/App/CMS.pm

    r595 r596  
    495495 
    496496    my $blog_id = $app->{ query }->param('blog_id'); 
    497  
    498     my $cache_list = make_module_cache_list($blog_id); 
     497         
     498        my $cache_list; 
     499        my $status_message; 
     500         
     501        if (MT->version_number >= 4.15) { 
     502      $cache_list = make_module_cache_list($blog_id); 
     503          $status_message = "Here are your blog's cached modules."; 
     504        } else { 
     505          $cache_list = ""; 
     506          $status_message = "This feature isn't relevant for versions of MT before 4.15."; 
     507        } 
    499508 
    500509    my $tmpl = $plugin->load_tmpl('list_module_caches.tmpl'); 
     
    502511    my $param; 
    503512 
    504     $param->{ 'status_message' } = "Here are your blog's cached modules."; 
     513    $param->{ 'status_message' } = $status_message; 
    505514    $param->{ 'cache_list' }   = $cache_list; 
    506515    $param->{ 'confirm_link' }   = "Templates";