File tree Expand file tree Collapse file tree 1 file changed +3
-5
lines changed
src/connection/syntaxChecker Expand file tree Collapse file tree 1 file changed +3
-5
lines changed Original file line number Diff line number Diff line change @@ -42,20 +42,18 @@ export class SQLStatementChecker implements IBMiComponent {
42
42
private readonly functionName = VALIDATOR_NAME ;
43
43
private readonly currentVersion = 5 ;
44
44
45
- private installedVersion = 1 ;
46
45
private library = "" ;
47
46
48
47
static get ( ) : SQLStatementChecker | undefined {
49
48
return getInstance ( ) ?. getConnection ( ) ?. getComponent < SQLStatementChecker > ( SQLStatementChecker . ID ) ;
50
49
}
51
50
52
51
reset ( ) {
53
- this . installedVersion = 0 ;
54
52
this . library = "" ;
55
53
}
56
54
57
55
getIdentification ( ) : ComponentIdentification {
58
- return { name : SQLStatementChecker . ID , version : this . installedVersion } ;
56
+ return { name : SQLStatementChecker . ID , version : this . currentVersion } ;
59
57
}
60
58
61
59
static async getVersionOf ( connection : IBMi , schema : string , name : string ) {
@@ -79,8 +77,8 @@ export class SQLStatementChecker implements IBMiComponent {
79
77
return `NeedsUpdate` ;
80
78
}
81
79
82
- this . installedVersion = await SQLStatementChecker . getVersionOf ( connection , this . library , this . functionName ) ;
83
- if ( this . installedVersion < this . currentVersion ) {
80
+ const installedVersion = await SQLStatementChecker . getVersionOf ( connection , this . library , this . functionName ) ;
81
+ if ( installedVersion < this . currentVersion ) {
84
82
return `NeedsUpdate` ;
85
83
}
86
84
You can’t perform that action at this time.
0 commit comments