protected function loadRow(array $row) {
        $settings = \json_decode($row['settings'], true);
        if($settings === null) {
            $this->client->emit('warn', 'MySQLProvider couldn\'t parse the settings stored for guild "'.$row['guild'].'". Error: '.\json_last_error_msg());
            return;
        }
        
        $settings = new \ArrayObject($settings, \ArrayObject::ARRAY_AS_PROPS);
        $this->settings->set($row['guild'], $settings);
        
        try {
            $this->setupGuild($row['guild']);
        } catch (\InvalidArgumentException $e) {
            $this->settings->delete($row['guild']);
            $this->runQuery('DELETE FROM `settings` WHERE `guild` = ?', array($row['guild']))->done(null, array($this->client, 'handlePromiseRejection'));
        }
    }
protected function loadRow(array $row) {
        $settings = \json_decode($row['settings'], true);
        if($settings === null) {
            $this->client->emit('warn', 'MySQLProvider couldn\'t parse the settings stored for guild "'.$row['guild'].'". Error: '.\json_last_error_msg());
            return;
        }
        
        $settings = new \ArrayObject($settings, \ArrayObject::ARRAY_AS_PROPS);
        $this->settings->set($row['guild'], $settings);
        
        try {
            $this->setupGuild($row['guild']);
        } catch (\InvalidArgumentException $e) {
            $this->settings->delete($row['guild']);
            $this->runQuery('DELETE FROM `settings` WHERE `guild` = ?', array($row['guild']))->done(null, array($this->client, 'handlePromiseRejection'));
        }
    }
protected function loadRow ( array $ row ) { $ settings = \ json_decode ( $ row [ 'settings' ] , true ) ; if ( $ settings === null ) { $ this -> client -> emit ( 'warn' , 'MySQLProvider couldn\'t parse the settings stored for guild "' . $ row [ 'guild' ] . '". Error: ' . \ json_last_error_msg ( ) ) ; return ; } $ settings = new \ ArrayObject ( $ settings , \ ArrayObject :: ARRAY_AS_PROPS ) ; $ this -> settings -> set ( $ row [ 'guild' ] , $ settings ) ; try { $ this -> setupGuild ( $ row [ 'guild' ] ) ; } catch ( \ InvalidArgumentException $ e ) { $ this -> settings -> delete ( $ row [ 'guild' ] ) ; $ this -> runQuery ( 'DELETE FROM `settings` WHERE `guild` = ?' , array ( $ row [ 'guild' ] ) ) -> done ( null , array ( $ this -> client , 'handlePromiseRejection' ) ) ; } }
Processes a database row.
@param array  $row
@return void
Processes a database row .