aboutsummaryrefslogtreecommitdiff
path: root/src/otp.rs
diff options
context:
space:
mode:
authorRobin Krahl <robin.krahl@ireas.org>2020-09-22 00:05:53 +0200
committerRobin Krahl <robin.krahl@ireas.org>2020-09-22 00:05:53 +0200
commit6a94c70a2224212e2310927aec7b512d562ee455 (patch)
tree6d205fbee84f2786abb00c1da5c7b2549e39f260 /src/otp.rs
parent5df790a77a8c81b58e7507e8da5d9ac4975a64f8 (diff)
downloadnitrokey-rs-6a94c70a2224212e2310927aec7b512d562ee455.tar.gz
nitrokey-rs-6a94c70a2224212e2310927aec7b512d562ee455.tar.bz2
Rename *lock fields of the Config structnext
libnitrokey calls the configuration fields that set bindings for the Num Lock, Caps Lock and Scroll Lock keys numlock, capslock, scrolllock. Due to a typo, scrolllock with three l was renamed to scrollock with two l in nitrokey-rs. To make the field names easier to read (and type) and consistent with the typical names for these keys, this patch changes them to num_lock, caps_lock and scroll_lock. In the doc comments, we now use the spelling “Num Lock”, “Caps Lock” and “Scroll Lock”.
Diffstat (limited to 'src/otp.rs')
-rw-r--r--src/otp.rs8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/otp.rs b/src/otp.rs
index 1d5f507..7b47a3b 100644
--- a/src/otp.rs
+++ b/src/otp.rs
@@ -347,8 +347,8 @@ pub struct OtpSlotData {
pub secret: String,
/// The OTP generation mode.
pub mode: OtpMode,
- /// If true, press the enter key after sending an OTP code using double-pressed
- /// numlock, capslock or scrolllock.
+ /// If true, press the enter key after sending an OTP code using double-pressed Num Lock, Caps
+ /// Lock or Scroll Lock.
pub use_enter: bool,
/// Set the token ID, see [OATH Token Identifier Specification][tokspec], section “Class A”.
///
@@ -385,8 +385,8 @@ impl OtpSlotData {
}
}
- /// Enables pressing the enter key after sending an OTP code using double-pressed numlock,
- /// capslock or scrollock.
+ /// Enables pressing the enter key after sending an OTP code using double-pressed Num Lock,
+ /// Caps Lock or Scroll Lock.
pub fn use_enter(mut self) -> OtpSlotData {
self.use_enter = true;
self