Fixed little issues in script