Fix files removing.
Patch from Michael.
Closes lp:1123519, thanks Michael.