Fix generating of appDir