Merged in release/release-1.09 (pull request #10)

Release/release 1.09

* Install missing plugins 
* rs set to 1

* rebase pantheon for aws

* rebase pantheon for aws

* prod config change

* prod config change

* fix campaing issue

* revert


Approved-by: Jay Sharma
This commit is contained in:
Rachit Bhargava
2023-12-27 20:55:58 +00:00
committed by Jay Sharma
parent 779393381f
commit 22f10a9edd
2154 changed files with 22313 additions and 209875 deletions

View File

@@ -48,16 +48,14 @@ class Wincher_Account_Action {
try {
$results = $this->client->get( self::ACCOUNT_URL );
$usage = $results['limits']['keywords']['usage'];
$limit = $results['limits']['keywords']['limit'];
$history = $results['limits']['history_days'];
$usage = $results['limits']['keywords']['usage'];
$limit = $results['limits']['keywords']['limit'];
return (object) [
'canTrack' => \is_null( $limit ) || $usage < $limit,
'limit' => $limit,
'usage' => $usage,
'historyDays' => $history,
'status' => 200,
'canTrack' => \is_null( $limit ) || $usage < $limit,
'limit' => $limit,
'usage' => $usage,
'status' => 200,
];
} catch ( \Exception $e ) {
return (object) [
@@ -74,13 +72,13 @@ class Wincher_Account_Action {
*/
public function get_upgrade_campaign() {
try {
$result = $this->client->get( self::UPGRADE_CAMPAIGN_URL );
$type = isset( $result['type'] ) ? $result['type'] : null;
$months = isset( $result['months'] ) ? $result['months'] : null;
$discount = isset( $result['value'] ) ? $result['value'] : null;
$result = $this->client->get( self::UPGRADE_CAMPAIGN_URL );
$type = $result['type'];
$months = $result['months'];
// We display upgrade discount only if it's a rate discount and positive months/discount.
if ( $type === 'RATE' && $months && $discount ) {
// We display upgrade discount only if it's a rate discount and positive months.
if ( $type === 'RATE' && $months && $months > 0 ) {
$discount = $result['value'];
return (object) [
'discount' => $discount,

View File

@@ -182,11 +182,10 @@ class Wincher_Keyphrases_Action {
*
* @param array|null $used_keyphrases The currently used keyphrases. Optional.
* @param string|null $permalink The current permalink. Optional.
* @param string|null $start_at The position start date. Optional.
*
* @return object The keyphrase chart data.
*/
public function get_tracked_keyphrases( $used_keyphrases = null, $permalink = null, $start_at = null ) {
public function get_tracked_keyphrases( $used_keyphrases = null, $permalink = null ) {
try {
if ( $used_keyphrases === null ) {
$used_keyphrases = $this->collect_all_keyphrases();
@@ -214,7 +213,6 @@ class Wincher_Keyphrases_Action {
[
'keywords' => $used_keyphrases,
'url' => $permalink,
'start_at' => $start_at,
]
),
[