diff --git a/lib/Connection.js b/lib/Connection.js index 274fe7b..a9efd3a 100644 --- a/lib/Connection.js +++ b/lib/Connection.js @@ -3,7 +3,7 @@ const { Cursor } = require('./Cursor'); class Connection { - CONNECTION_CLOSED_ERROR = 'Connection has already been closed!'; + static CONNECTION_CLOSED_ERROR = 'Connection has already been closed!'; /** * An open connection to the database made through an ODBC driver @@ -26,7 +26,7 @@ class Connection { get autocommit() { if (!this.odbcConnection) { - throw new Error(CONNECTION_CLOSED_ERROR); + throw new Error(Connection.CONNECTION_CLOSED_ERROR); } return this.odbcConnection.autocommit; }