Engine crashes when using NewObject<>()

My goal is to add to the Inventory all the Weapons the player should have when the game starts.
Is that way good (spawn actor)?