Switched to core.Main.addMembers
Fixed missing headers