Fix bug in getter