Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion classes/Tools_V2.php
Original file line number Diff line number Diff line change
Expand Up @@ -327,7 +327,7 @@ private function get_tools_fields() {
),
),
'tutor_rest_api' => array(
'label' => __( 'Rest API', 'tutor' ),
'label' => __( 'REST API', 'tutor' ),
'slug' => 'tutor_rest_api',
'desc' => __( 'Token List', 'tutor' ),
'template' => 'manage-tokens',
Expand Down
22 changes: 10 additions & 12 deletions views/pages/tools/manage-tokens.php
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@
?>
<div class="tutor-option-main-title">
<div class="tutor-fs-4 tutor-fw-medium tutor-color-black">
<?php esc_html_e( 'Rest API', 'tutor' ); ?>
<?php esc_html_e( 'REST API', 'tutor' ); ?>
</div>
</div>

Expand All @@ -54,11 +54,10 @@
<div class="tutor-fs-7 tutor-color-muted tutor-mt-8">
<?php
printf(
/* translators: 1: min days, 2: max days, 3: default days */
esc_html__( 'Lifetime in days before access tokens expire. Allowed range: %1$d–%2$d. Default: %3$d day(s). Use 0 for no expiration.', 'tutor' ),
/* translators: 1: min days, 2: max days */
esc_html__( 'Set how many days an access token stays valid. Allowed range: %1$d to %2$d. Enter 0 for no expiration', 'tutor' ),
(int) RestAuth::MIN_TTL_DAYS,
(int) RestAuth::MAX_TTL_DAYS,
(int) $default_access_days
(int) RestAuth::MAX_TTL_DAYS
);
?>
</div>
Expand All @@ -85,11 +84,10 @@ class="tutor-form-control tutor-w-160"
<div class="tutor-fs-7 tutor-color-muted tutor-mt-8">
<?php
printf(
/* translators: 1: min days, 2: max days, 3: default days */
esc_html__( 'Lifetime in days before refresh tokens expire. Allowed range: %1$d–%2$d. Default: %3$d day(s). Must be greater than the access token lifetime. Use 0 for no expiration.', 'tutor' ),
/* translators: 1: min days, 2: max days */
esc_html__( 'Set how many days a refresh token stays valid. Allowed range: %1$d to %2$d. Enter 0 for no expiration. It must be longer than the Access Token Lifetime.', 'tutor' ),
(int) RestAuth::MIN_TTL_DAYS,
(int) RestAuth::MAX_TTL_DAYS,
(int) $default_refresh_days
(int) RestAuth::MAX_TTL_DAYS
);
?>
</div>
Expand All @@ -109,7 +107,7 @@ class="tutor-form-control tutor-w-160"
</div>

<div class="tutor-fs-7 tutor-color-warning tutor-mt-12 tutor-mb-16">
<?php esc_html_e( 'Note: Setting a lifetime to 0 means the token never expires. Tutor LMS strongly recommends against this, because a stolen token would remain valid indefinitely.', 'tutor' ); ?>
<?php esc_html_e( 'Note: It\'s not recommended to set the token lifetime to 0 (no expiration). A compromised token would remain valid indefinitely and increase security risk.', 'tutor' ); ?>
</div>

<div class="tutor-option-field-row">
Expand Down Expand Up @@ -213,15 +211,15 @@ class="tutor-form-control tutor-w-160"
<textarea name="description" id="description" class="tutor-form-control" cols="30" rows="3" placeholder="<?php esc_html_e( 'Write here...', 'tutor' ); ?>"></textarea>
</div>
<div class="tutor-fs-7 tutor-color-warning">
<?php esc_html_e( 'The API secret will be shown only once after generation. Copy it immediately and store it in a secure location. You will not be able to view it again.', 'tutor' ); ?>
<?php esc_html_e( 'The API Secret will be shown only once. Copy it now and store it in a secure location. It cannot be retrieved later.', 'tutor' ); ?>
</div>
</div>
</div>
</div>

<div id="tutor-generated-credentials" class="tutor-d-none">
<div class="tutor-fs-7 tutor-color-warning tutor-mb-16">
<?php esc_html_e( 'Copy your API key and secret now and store them in a secure location. The secret will not be shown again.', 'tutor' ); ?>
<?php esc_html_e( 'Make sure to copy both your API key and Secret now. The secret cannot be retrieved later.', 'tutor' ); ?>
</div>
<div class="tutor-mb-16">
<label class="tutor-form-label" for="tutor-generated-api-key">
Expand Down
Loading