File tree Expand file tree Collapse file tree 1 file changed +6
-3
lines changed Expand file tree Collapse file tree 1 file changed +6
-3
lines changed Original file line number Diff line number Diff line change @@ -136,7 +136,7 @@ class CustomExtensionModal extends React.Component {
136136 if ( ! loadedIds . includes ( this . props . swapId ) ) {
137137 for ( const ext of loadedIds ) this . props . vm . extensionManager . removeExtension ( ext ) ;
138138 // eslint-disable-next-line no-alert
139- alert ( 'The extension you used to for the edit had a different id to the one you where editing.' ) ;
139+ alert ( 'The extension you used for the edit had a different ID than the one you were editing.' ) ;
140140 }
141141 this . props . vm . runtime . _removeExtensionPrimitive ( this . props . swapId ) ;
142142 loadedIds . forEach ( extId => {
@@ -152,8 +152,11 @@ class CustomExtensionModal extends React.Component {
152152 } catch ( err ) {
153153 failed = true ;
154154 log . error ( err ) ;
155- // eslint-disable-next-line no-alert
156- alert ( err ) ;
155+
156+ if ( err ) {
157+ // eslint-disable-next-line no-alert
158+ alert ( err ) ;
159+ }
157160 } finally {
158161 if ( failed && this . props . swapId ) {
159162 // eslint-disable-next-line no-alert
You can’t perform that action at this time.
0 commit comments