fixed ordering tasks issue