Skip to content

Commit

Permalink
Add a REMOTE_API_URL const
Browse files Browse the repository at this point in the history
  • Loading branch information
aristath committed Apr 11, 2024
1 parent 1235e48 commit 8a309fe
Showing 1 changed file with 10 additions and 3 deletions.
13 changes: 10 additions & 3 deletions classes/class-onboard.php
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,14 @@ class Onboard {
*
* @var string
*/
const REMOTE_URL = 'https://progressplanner.com';
const REMOTE_DOMAIN = 'https://progressplanner.com';

/**
* The remote API endpoints namespace URL.
*
* @var string
*/
const REMOTE_API_URL = '/wp-json/progress-planner-saas/v1/';

/**
* Constructor.
Expand Down Expand Up @@ -138,7 +145,7 @@ public function save_onboard_response() {
* @return string
*/
public static function get_remote_nonce_url() {
return self::REMOTE_URL . '/wp-json/progress-planner-saas/v1/get-nonce';
return self::REMOTE_DOMAIN . self::REMOTE_API_URL . 'get-nonce';
}

/**
Expand All @@ -147,6 +154,6 @@ public static function get_remote_nonce_url() {
* @return string
*/
public static function get_remote_url() {
return self::REMOTE_URL . '/wp-json/progress-planner-saas/v1/onboard';
return self::REMOTE_DOMAIN . self::REMOTE_API_URL . 'onboard';
}
}

0 comments on commit 8a309fe

Please sign in to comment.