@@ -102,8 +102,7 @@ |
||
102 | 102 | $db->begin(); |
103 | 103 | $result = $db->insert( self::TABLE_NAME, $accumulator ); |
104 | 104 | $db->commit(); |
105 | - } |
|
106 | - catch( DBError $ex ) { |
|
105 | + } catch( DBError $ex ) { |
|
107 | 106 | $db->rollback(); |
108 | 107 | throw $ex; |
109 | 108 | } |
@@ -95,16 +95,14 @@ discard block |
||
95 | 95 | intval( $data[6] ), |
96 | 96 | new ItemId( $data[7] ) |
97 | 97 | ); |
98 | - } |
|
99 | - catch( \InvalidArgumentException $e ) { |
|
98 | + } catch( \InvalidArgumentException $e ) { |
|
100 | 99 | exit( 'Input file has bad formatted values.' ); |
101 | 100 | } |
102 | 101 | $dumpIds[] = $dumpMetaInformation->getDumpId(); |
103 | 102 | |
104 | 103 | try { |
105 | 104 | $this->dumpMetaInformationStore->save( $dumpMetaInformation ); |
106 | - } |
|
107 | - catch( \DBError $e ) { |
|
105 | + } catch( \DBError $e ) { |
|
108 | 106 | exit( 'Unknown database error occurred.' ); |
109 | 107 | } |
110 | 108 | |
@@ -138,8 +136,7 @@ discard block |
||
138 | 136 | if ( $data === false || ++$i % $this->importSettings->getBatchSize() === 0 ) { |
139 | 137 | try { |
140 | 138 | $this->externalDataRepo->insertBatch( $accumulator ); |
141 | - } |
|
142 | - catch( \DBError $e ) { |
|
139 | + } catch( \DBError $e ) { |
|
143 | 140 | exit( 'Unknown database error occurred.' ); |
144 | 141 | } |
145 | 142 | wfGetLBFactory()->waitForReplication(); |