Skip to content

Commit

Permalink
Clarify that an API key and API secret are both needed (#171)
Browse files Browse the repository at this point in the history
Without an API secret, lots of plugin functionality would silently fail. Bad UX!
This makes it clear that both are needed.

Closes #146
  • Loading branch information
tnorthcutt authored Feb 1, 2019
1 parent b35a7d7 commit afd6225
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions admin/section/class-convertkit-settings-general.php
Original file line number Diff line number Diff line change
Expand Up @@ -137,7 +137,8 @@ public function api_key_callback() {
isset( $this->options['api_key'] ) ? esc_attr( $this->options['api_key'] ) : ''
);

$html .= '<p class="description"><a href="https://app.convertkit.com/account/edit" target="_blank">' . __( 'Get your ConvertKit API Key', 'convertkit' ) . '</a></p>';
$html .= '<p class="description"><a href="https://app.convertkit.com/account/edit" target="_blank">' . __( 'Get your ConvertKit API Key.', 'convertkit' ) . '</a>';
$html .= ' ' . __( 'Required for proper plugin function.', 'convertkit' ) . '</p>';

$has_api = isset( $this->options['api_key'] ) ? esc_attr( $this->options['api_key'] ) : false;

Expand All @@ -159,7 +160,7 @@ public function api_secret_callback() {

$html .= '<p class="description"><a href="https://app.convertkit.com/account/edit" target="_blank">';
$html .= __( 'Get your ConvertKit API Secret.', 'convertkit' ) . '</a>';
$html .= ' ' . __( 'This setting is required to unsubscribe subscribers.', 'convertkit' ) . '</p>';
$html .= ' ' . __( 'Required for proper plugin function.', 'convertkit' ) . '</p>';

echo $html; // WPCS: XSS ok.
}
Expand Down

0 comments on commit afd6225

Please sign in to comment.