Fix bug with relative resources