Reverted to original code (both work)