Fixed resource access problem.