Fix object onClick (previously failed change)

I'm unsure how but a previous change in this pull request never merged correctly (probably still due to my inexperience with github)  Regardless, this tiny patch fixes the bug