Added null check for when material is null

Prevents null from being added to mods.BlockIdsRequiringAccessTrust and mods.BlockIdsRequiringContainerTrust