panel/app/src/panel/structure/store.php
/**
   * Resets store if necessary to stay in sync with content file
   */
Resets store if necessary to stay in sync with content file
Resets store if necessary to stay in sync with content file
public function sync() {
    $file     = $this->structure->model()->textfile();
    $ageModel = f::exists($file) ? f::modified($file) : 0;
    $ageStore = s::get($this->id() . '_age');
    if($ageStore < $ageModel) {
      $this->reset();
      $this->age = $ageModel;
    } else {
      $this->age = $ageStore;
    }
  }
public function sync ( ) { $ file = $ this -> structure -> model ( ) -> textfile ( ) ; $ ageModel = f :: exists ( $ file ) ? f :: modified ( $ file ) : 0 ; $ ageStore = s :: get ( $ this -> id ( ) . '_age' ) ; if ( $ ageStore < $ ageModel ) { $ this -> reset ( ) ; $ this -> age = $ ageModel ; } else { $ this -> age = $ ageStore ; } }
Resets store if necessary to stay in sync with content file
Resets store if necessary to stay in sync with content file