I am currently working on a class with code to help manage a database.
export class DatabaseHelper {
public browserID : number;
private ConfigID = 17;
}
Within this class, I am attempting to access the value of ConfigID
SetBrowserID() {
browser.getCapabilities().then(function (cap) {
this.browserID = new commFnctions.appdata().getBrowserIDFromBrowserName(cap.get('browserName'));
});
}
However, I am encountering an error message:
TypeError: Cannot set property 'browserID' of undefined