Check for obj.prototype before reading or assigning