diff --git a/wp-rest/Controller/Rest.php b/wp-rest/Controller/Rest.php
index f3d6cf349a1f7de3f266b62fac1b2b9e4ba5f152..1fe15caae97793ce16d4e3f7c9c9a06da58674f4 100644
--- a/wp-rest/Controller/Rest.php
+++ b/wp-rest/Controller/Rest.php
@@ -519,7 +519,7 @@ class Rest extends Base {
 
 			// If this fails, get it from config.
 			if ( $domain_id === 0 ) {
-				$domain_id = CRM_Core_Config::domainID();
+				$domain_id = \CRM_Core_Config::domainID();
 			}
 
 			// Call API.