Skip to content

Commit a913e00

Browse files
committed
Updating Rust version to 1.0.87
This matches the Rust version Destkop v141. It fixes the cargo-audit GH action, which was failing before because the Rust version was too old. * Applied changes from `cargo clippy --fix`. * Updated docstring indentation because of new clippy errors * Updating ctest `0.4.10`
1 parent 4d9d334 commit a913e00

File tree

27 files changed

+53
-65
lines changed

27 files changed

+53
-65
lines changed

Cargo.lock

Lines changed: 2 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

components/fxa-client/src/device.rs

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -53,8 +53,7 @@ impl FirefoxAccount {
5353
supported_capabilities: Vec<DeviceCapability>,
5454
) -> ApiResult<LocalDevice> {
5555
// UniFFI doesn't have good handling of lists of references, work around it.
56-
let supported_capabilities: Vec<_> =
57-
supported_capabilities.into_iter().map(Into::into).collect();
56+
let supported_capabilities: Vec<_> = supported_capabilities.into_iter().collect();
5857
self.internal
5958
.lock()
6059
.initialize_device(name, device_type, &supported_capabilities)
@@ -188,8 +187,7 @@ impl FirefoxAccount {
188187
&self,
189188
supported_capabilities: Vec<DeviceCapability>,
190189
) -> ApiResult<LocalDevice> {
191-
let supported_capabilities: Vec<_> =
192-
supported_capabilities.into_iter().map(Into::into).collect();
190+
let supported_capabilities: Vec<_> = supported_capabilities.into_iter().collect();
193191
self.internal
194192
.lock()
195193
.ensure_capabilities(&supported_capabilities)

components/fxa-client/src/internal/config.rs

Lines changed: 3 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -94,29 +94,26 @@ impl Config {
9494

9595
pub fn connect_another_device_url(&self) -> Result<Url> {
9696
self.content_url_path("connect_another_device")
97-
.map_err(Into::into)
9897
}
9998

10099
pub fn pair_url(&self) -> Result<Url> {
101-
self.content_url_path("pair").map_err(Into::into)
100+
self.content_url_path("pair")
102101
}
103102

104103
pub fn pair_supp_url(&self) -> Result<Url> {
105-
self.content_url_path("pair/supp").map_err(Into::into)
104+
self.content_url_path("pair/supp")
106105
}
107106

108107
pub fn oauth_force_auth_url(&self) -> Result<Url> {
109108
self.content_url_path("oauth/force_auth")
110-
.map_err(Into::into)
111109
}
112110

113111
pub fn settings_url(&self) -> Result<Url> {
114-
self.content_url_path("settings").map_err(Into::into)
112+
self.content_url_path("settings")
115113
}
116114

117115
pub fn settings_clients_url(&self) -> Result<Url> {
118116
self.content_url_path("settings/clients")
119-
.map_err(Into::into)
120117
}
121118

122119
pub fn auth_url(&self) -> Result<Url> {

components/fxa-client/src/internal/device.rs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -417,7 +417,6 @@ impl TryFrom<Device> for crate::Device {
417417
commands::close_tabs::COMMAND_NAME => Some(DeviceCapability::CloseTabs),
418418
_ => None,
419419
})
420-
.map(Into::into)
421420
.collect();
422421
Ok(crate::Device {
423422
id: d.common.id,

components/fxa-client/src/internal/mod.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -160,7 +160,7 @@ impl FirefoxAccount {
160160
/// all the details of their account.
161161
///
162162
/// * `entrypoint` - Application-provided string identifying the UI touchpoint
163-
/// through which the page was accessed, for metrics purposes.
163+
/// through which the page was accessed, for metrics purposes.
164164
pub fn get_manage_account_url(&mut self, entrypoint: &str) -> Result<String> {
165165
let mut url = self.state.config().settings_url()?;
166166
url.query_pairs_mut().append_pair("entrypoint", entrypoint);
@@ -177,7 +177,7 @@ impl FirefoxAccount {
177177
/// the devices connected to their account.
178178
///
179179
/// * `entrypoint` - Application-provided string identifying the UI touchpoint
180-
/// through which the page was accessed, for metrics purposes.
180+
/// through which the page was accessed, for metrics purposes.
181181
pub fn get_manage_devices_url(&mut self, entrypoint: &str) -> Result<String> {
182182
let mut url = self.state.config().settings_clients_url()?;
183183
url.query_pairs_mut().append_pair("entrypoint", entrypoint);

components/fxa-client/src/internal/oauth.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -562,7 +562,7 @@ impl TryFrom<AccessTokenInfo> for crate::AccessTokenInfo {
562562
Ok(crate::AccessTokenInfo {
563563
scope: info.scope,
564564
token: info.token,
565-
key: info.key.map(ScopedKey::into),
565+
key: info.key,
566566
expires_at: info.expires_at.try_into()?,
567567
})
568568
}

components/logins/src/login.rs

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -105,11 +105,11 @@
105105
//! - Add a field with the original unicode versions of the URLs instead of punycode?
106106
//!
107107
//! - `sec_fields`: The `username` and `password` for the site, stored as a encrypted JSON
108-
//! representation of an `SecureLoginFields`.
108+
//! representation of an `SecureLoginFields`.
109109
//!
110110
//! This field is required and usually encrypted. There are two different value types:
111-
//! - Plaintext empty string: Used for deleted records
112-
//! - Encrypted value: The credentials associated with the login.
111+
//! - Plaintext empty string: Used for deleted records
112+
//! - Encrypted value: The credentials associated with the login.
113113
//!
114114
//! - `http_realm`: The challenge string for HTTP Basic authentication, if any.
115115
//!
@@ -242,7 +242,7 @@
242242
//! - test that we correctly merge dupes
243243
//!
244244
//! - `time_password_changed`: A lower bound on the time that the `password` field was last changed, in integer
245-
//! milliseconds from the unix epoch.
245+
//! milliseconds from the unix epoch.
246246
//!
247247
//! Changes to other fields (such as `username`) are not reflected in this timestamp.
248248
//! This is a lower bound because some legacy sync clients do not record this information;
@@ -273,10 +273,10 @@
273273
//! callers to ensure that they're only working with valid records:
274274
//!
275275
//! - `Login::check_valid()`: Checks validity of a login record, returning `()` if it is valid
276-
//! or an error if it is not.
276+
//! or an error if it is not.
277277
//!
278278
//! - `Login::fixup()`: Returns either the existing login if it is valid, a clone with invalid fields
279-
//! fixed up if it was safe to do so, or an error if the login is irreparably invalid.
279+
//! fixed up if it was safe to do so, or an error if the login is irreparably invalid.
280280
281281
use crate::{encryption::EncryptorDecryptor, error::*};
282282
use rusqlite::Row;

components/nimbus/src/evaluator.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -135,8 +135,8 @@ pub fn evaluate_enrollment(
135135
/// - `app_context` The application parameters to use for targeting purposes
136136
/// - `exp` The `Experiment` to evaluate
137137
/// - `is_release` Supports two modes:
138-
/// if `true`, available means available for enrollment: i.e. does the `app_name` and `channel` match.
139-
/// if `false`, available means available for testing: i.e. does only the `app_name` match.
138+
/// if `true`, available means available for enrollment: i.e. does the `app_name` and `channel` match.
139+
/// if `false`, available means available for testing: i.e. does only the `app_name` match.
140140
///
141141
/// # Returns:
142142
/// Returns `true` if the experiment matches the targeting

components/nimbus/src/stateful/persistence.rs

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -114,15 +114,15 @@ pub enum StoreId {
114114
/// are serialized items whose type depends on the constant. Known constraints
115115
/// include:
116116
/// * "db_version": u16, the version number of the most revent migration
117-
/// applied to this database.
117+
/// applied to this database.
118118
/// * "nimbus-id": String, the randomly-generated identifier for the
119-
/// current client instance.
119+
/// current client instance.
120120
/// * "user-opt-in": bool, whether the user has explicitly opted in or out
121-
/// of participating in experiments.
121+
/// of participating in experiments.
122122
/// * "installation-date": a UTC DateTime string, defining the date the consuming app was
123-
/// installed
123+
/// installed
124124
/// * "update-date": a UTC DateTime string, defining the date the consuming app was
125-
/// last updated
125+
/// last updated
126126
/// * "app-version": String, the version of the app last persisted
127127
Meta,
128128
/// Store containing pending updates to experiment data.

components/places/src/bookmark_sync/mod.rs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -78,10 +78,10 @@ impl ToSql for SyncedBookmarkKind {
7878
/// `mozISyncedBookmarksMerger`. In short:
7979
/// * `Valid` means the record is valid and should be merged as usual.
8080
/// * `Reupload` means a remote item can be fixed up and applied,
81-
/// and should be reuploaded.
81+
/// and should be reuploaded.
8282
/// * `Replace` means a remote item isn't valid at all, and should either be
83-
/// replaced with a valid local copy, or deleted if a valid local copy
84-
/// doesn't exist.
83+
/// replaced with a valid local copy, or deleted if a valid local copy
84+
/// doesn't exist.
8585
#[derive(Clone, Copy, Debug, Eq, PartialEq, Ord, PartialOrd, Hash)]
8686
#[repr(u8)]
8787
pub enum SyncedBookmarkValidity {

0 commit comments

Comments
 (0)