File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 196196 } ) ;
197197 } ;
198198
199- before . check ( {
200- context : context ,
201- response : {
202- success : function ( result ) {
203- // true means content exists
204- if ( result ) {
205- load ( ) ;
206- } else {
207- cloudStack . dialog . confirm ( {
208- message : before . messages . confirm ,
209- action : function ( ) {
210- $loading . appendTo ( $dashboardItem . closest ( '.vpc-network-chart' ) ) ;
211- before . action ( {
212- context : context ,
213- response : {
214- success : function ( ) {
215- $loading . remove ( ) ;
216- $dashboardItem . closest ( '.vpc-network-chart' ) . trigger ( 'reload' ) ;
217- load ( ) ;
199+ if ( before ) {
200+ before . check ( {
201+ context : context ,
202+ response : {
203+ success : function ( result ) {
204+ // true means content exists
205+ if ( result ) {
206+ load ( ) ;
207+ } else {
208+ cloudStack . dialog . confirm ( {
209+ message : before . messages . confirm ,
210+ action : function ( ) {
211+ $loading . appendTo ( $dashboardItem . closest ( '.vpc-network-chart' ) ) ;
212+ before . action ( {
213+ context : context ,
214+ response : {
215+ success : function ( ) {
216+ $loading . remove ( ) ;
217+ $dashboardItem . closest ( '.vpc-network-chart' ) . trigger ( 'reload' ) ;
218+ load ( ) ;
219+ }
218220 }
219- }
220- } ) ;
221- }
222- } )
221+ } ) ;
222+ }
223+ } )
224+ }
223225 }
224226 }
225- }
226- } ) ;
227+ } ) ;
228+ }
227229 } ) ;
228230 } ) ;
229231
You can’t perform that action at this time.
0 commit comments