Small fixes and style improvements for tasks