R: fix antipattern
This commit is contained in:
parent
b00ba62f16
commit
49ad4e2437
2 changed files with 2 additions and 3 deletions
|
|
@ -4,6 +4,7 @@
|
||||||
- [x] dead code
|
- [x] dead code
|
||||||
- [x] magic strings/numbers
|
- [x] magic strings/numbers
|
||||||
- [x] bad naming
|
- [x] bad naming
|
||||||
|
- [x] antipattern
|
||||||
- [ ] scopes
|
- [ ] scopes
|
||||||
|
|
||||||
# RPP
|
# RPP
|
||||||
|
|
|
||||||
|
|
@ -44,9 +44,7 @@ class Rover {
|
||||||
val position: String
|
val position: String
|
||||||
get() = "${state.positionX} ${state.positionY} ${state.direction}"
|
get() = "${state.positionX} ${state.positionY} ${state.direction}"
|
||||||
|
|
||||||
fun pos(): String {
|
fun pos(): String = position
|
||||||
return position
|
|
||||||
}
|
|
||||||
|
|
||||||
private var state = RoverState()
|
private var state = RoverState()
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue