diff --git a/indra/newview/llvoicevivox.cpp b/indra/newview/llvoicevivox.cpp
index a754e857ac398ea387396027ac13495efc20d810..25df528d897bebea8ef27777b1af78b569727ded 100644
--- a/indra/newview/llvoicevivox.cpp
+++ b/indra/newview/llvoicevivox.cpp
@@ -782,15 +782,13 @@ bool LLVivoxVoiceClient::provisionVoiceAccount()
         llcoro::suspend();
     }
 
-    LLViewerRegion *region = gAgent.getRegion();
-
-    while (!region->capabilitiesReceived())
+    while (!gAgent.getRegion()->capabilitiesReceived())
     {
         // *TODO* Pump a message for wake up.
         llcoro::suspend();
     }
 
-    std::string url = region->getCapability("ProvisionVoiceAccountRequest");
+    std::string url = gAgent.getRegionCapability("ProvisionVoiceAccountRequest");
 
     LLCore::HttpRequest::policy_t httpPolicy(LLCore::HttpRequest::DEFAULT_POLICY_ID);
     LLCoreHttpUtil::HttpCoroutineAdapter::ptr_t