some fixes when no tasks are present or script called wrong