Added check for res folder