Added new logic, but still needs fix