Added fix for old cases with opened tasks