Team2168 / 2020_SwerveBot

Repo for development of field oriented swerve chassis tests
1 stars 0 forks source link

Removed key attr. from all smartdashboard types #52

Closed natejank closed 3 years ago

natejank commented 3 years ago

I had forgotten how inheritance works, and this had been conflicting with the super.key value, and was therefore resulting in a NPE, because each constructor referenced back to the parent constructor, and therefore the parent instance, leaving the child instance uninitialized.

By removing the key member variable from all child classes, referencing key calls back to the abstract parent class (because this variable is protected instead of private), and everything works as expected.