Fixed small bug with resources