Fixed error with incorrect object usage