created initializeResources function