Cli/Migrate.php
private function getVersion()
    {
        $select = new QueryBuilder();
        $versionRow = $select
            ->query("SELECT value FROM {$this->table} WHERE param = 'migration_version'")
            ->fetchRow();

        if (!isset($versionRow['value'])) die("Error: Please init the Crater Migration");
        return $versionRow['value'];
    }
private function getVersion()
    {
        $select = new QueryBuilder();
        $versionRow = $select
            ->query("SELECT value FROM {$this->table} WHERE param = 'migration_version'")
            ->fetchRow();

        if (!isset($versionRow['value'])) die("Error: Please init the Crater Migration");
        return $versionRow['value'];
    }
private function getVersion ( ) { $ select = new QueryBuilder ( ) ; $ versionRow = $ select -> query ( "SELECT value FROM {$this->table} WHERE param = 'migration_version'" ) -> fetchRow ( ) ; if ( ! isset ( $ versionRow [ 'value' ] ) ) die ( "Error: Please init the Crater Migration" ) ; return $ versionRow [ 'value' ] ; }
Get current version of database
Get current version of database