y for magic function 2-fixed bug