Skip to content

Commit e56b69e

Browse files
authored
Added real getter and setter
1 parent d7b8cc1 commit e56b69e

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

README.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -952,7 +952,7 @@ bankAccount.withdraw(100);
952952
```javascript
953953
class BankAccount {
954954
constructor(balance = 1000) {
955-
this_balance = balance;
955+
this._balance = balance;
956956
}
957957

958958
// It doesn't have to be prefixed with `get` or `set` to be a getter/setter

0 commit comments

Comments
 (0)