@@ -46,7 +46,7 @@ |
||
| 46 | 46 | ['name','=','Other Name'], |
| 47 | 47 | 'OR' => ['email','LIKE','[email protected]'] |
| 48 | 48 | ])->execute(); |
| 49 | -}catch(Exception $er){ |
|
| 49 | +} catch(Exception $er){ |
|
| 50 | 50 | |
| 51 | 51 | die($er->getCode().' - '.$er->getMessage()); |
| 52 | 52 | |
@@ -5,10 +5,10 @@ |
||
| 5 | 5 | use HnrAzevedo\Datamanager\Datamanager; |
| 6 | 6 | |
| 7 | 7 | /** |
| 8 | - * @property string $name |
|
| 9 | - * @property string $email |
|
| 10 | - * @property string $password |
|
| 11 | - */ |
|
| 8 | + * @property string $name |
|
| 9 | + * @property string $email |
|
| 10 | + * @property string $password |
|
| 11 | + */ |
|
| 12 | 12 | class User extends Datamanager{ |
| 13 | 13 | |
| 14 | 14 | public function __construct() |
@@ -33,7 +33,7 @@ discard block |
||
| 33 | 33 | $stmt = Connect::getInstance()->prepare("{$query}"); |
| 34 | 34 | $stmt->execute($data); |
| 35 | 35 | return $stmt->fetchAll(PDO::FETCH_ASSOC); |
| 36 | - }catch(Exception $exception){ |
|
| 36 | + } catch(Exception $exception){ |
|
| 37 | 37 | $this->fail = $exception; |
| 38 | 38 | } |
| 39 | 39 | return []; |
@@ -45,7 +45,7 @@ discard block |
||
| 45 | 45 | $stmt = Connect::getInstance()->prepare("DESCRIBE {$this->table}"); |
| 46 | 46 | $stmt->execute(); |
| 47 | 47 | return $stmt->fetchAll(PDO::FETCH_ASSOC); |
| 48 | - }catch(Exception $exception){ |
|
| 48 | + } catch(Exception $exception){ |
|
| 49 | 49 | $this->fail = $exception; |
| 50 | 50 | return []; |
| 51 | 51 | } |
@@ -24,7 +24,7 @@ |
||
| 24 | 24 | } |
| 25 | 25 | |
| 26 | 26 | if(!Connect::getInstance()->inTransaction()){ |
| 27 | - return Connect::getInstance()->beginTransaction(); |
|
| 27 | + return Connect::getInstance()->beginTransaction(); |
|
| 28 | 28 | } |
| 29 | 29 | |
| 30 | 30 | switch ($transaction) { |
@@ -387,7 +387,7 @@ discard block |
||
| 387 | 387 | $this->check_fail(); |
| 388 | 388 | |
| 389 | 389 | $this->transaction('commit'); |
| 390 | - }catch(Exception $er){ |
|
| 390 | + } catch(Exception $er){ |
|
| 391 | 391 | $this->transaction('rollback'); |
| 392 | 392 | throw $er; |
| 393 | 393 | } |
@@ -426,7 +426,7 @@ discard block |
||
| 426 | 426 | |
| 427 | 427 | $this->transaction('commit'); |
| 428 | 428 | |
| 429 | - }catch(Exception $er){ |
|
| 429 | + } catch(Exception $er){ |
|
| 430 | 430 | $this->transaction('rollback'); |
| 431 | 431 | throw $er; |
| 432 | 432 | } |