Addedd input handling