fix closing last tab in task
fix closing last tab in task

We should eventually find a better way to share code between these two
modules, but this will work for now

minbrowser/min,minbrowser/min,minbrowser/min