Feature #4977: Add path information to removeDirectory error message
Feature #4977: Improve updateAssets function