File tree Expand file tree Collapse file tree 2 files changed +4
-4
lines changed Expand file tree Collapse file tree 2 files changed +4
-4
lines changed Original file line number Diff line number Diff line change @@ -323,12 +323,12 @@ export class ObjectScriptDebugSession extends LoggingDebugSession {
323
323
await Promise . all (
324
324
xdebugBreakpoints . map ( async ( breakpoint , index ) => {
325
325
try {
326
- if ( breakpoint . hitCondition && ! / ^ \d + $ / . test ( breakpoint . hitCondition ) ) {
327
- // The user-defined hitCondition wasn't an integer
326
+ if ( breakpoint . hitCondition && ! / ^ [ 1 - 9 ] \d * $ / . test ( breakpoint . hitCondition ) ) {
327
+ // The user-defined hitCondition wasn't a positive integer
328
328
vscodeBreakpoints [ index ] = {
329
329
verified : false ,
330
330
line : breakpoint . line ,
331
- message : "Hit Count must be an integer" ,
331
+ message : "Hit Count must be a positive integer" ,
332
332
} ;
333
333
} else {
334
334
await this . _connection . sendBreakpointSetCommand ( breakpoint ) ;
Original file line number Diff line number Diff line change @@ -159,7 +159,7 @@ export abstract class Breakpoint {
159
159
this . state = breakpointNode . getAttribute ( "state" ) as BreakpointState ;
160
160
} else {
161
161
this . type = rest [ 0 ] ;
162
- this . hitCondition = rest [ 1 ] ;
162
+ this . hitCondition = rest [ 1 ] . trim ( ) ;
163
163
this . state = "enabled" ;
164
164
}
165
165
}
You can’t perform that action at this time.
0 commit comments