Fixing UI layer bug