Core/Misc: Use boost::in_place() to initialize optionals.
* Improves commit 800d5d8939
* Thanks @Shauren for this great suggestion.
This commit is contained in:
@@ -143,7 +143,7 @@ WorldPacket const* WorldPackets::Spells::AuraUpdate::Write()
|
||||
|
||||
ByteBuffer& operator>>(ByteBuffer& buffer, Optional<WorldPackets::Spells::TargetLocation>& location)
|
||||
{
|
||||
location = WorldPackets::Spells::TargetLocation();
|
||||
location = boost::in_place();
|
||||
buffer >> location->Transport;
|
||||
buffer >> location->Location.m_positionX;
|
||||
buffer >> location->Location.m_positionY;
|
||||
|
||||
Reference in New Issue
Block a user