Skip to content

Commit b06a34d

Browse files
committed
Fix errors
1 parent 769f9c0 commit b06a34d

File tree

6 files changed

+11
-10
lines changed

6 files changed

+11
-10
lines changed

browser/data-browser/src/components/forms/ResourceSelector.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,12 +14,12 @@ import React, {
1414
useCallback,
1515
} from 'react';
1616
import { ErrMessage, InputWrapper } from './InputStyles';
17-
import { DropdownInput } from './DropdownInput';
1817
import { Dialog, useDialog } from '../Dialog';
1918
import { DialogTreeContext } from '../Dialog/dialogContext';
2019
import { useSettings } from '../../helpers/AppSettings';
2120
import styled from 'styled-components';
2221
import { NewFormDialog } from './NewForm/NewFormDialog';
22+
import { DropdownInput } from './ResourceSelector/DropdownInput';
2323

2424
interface ResourceSelectorProps {
2525
/**

lib/src/collections.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -494,7 +494,7 @@ mod test {
494494

495495
#[test]
496496
fn create_collection_nested_members_and_sorting() {
497-
let store = crate::Store::init().unwrap();
497+
let mut store = crate::Store::init().unwrap();
498498
store.populate().unwrap();
499499
let collection_builder = CollectionBuilder {
500500
subject: "test_subject".into(),
@@ -560,7 +560,7 @@ mod test {
560560
#[ignore]
561561
// TODO: This currently only tests atomicdata.dev, should test local resources. These need to be rewritten
562562
fn get_collection_params() {
563-
let store = crate::Store::init().unwrap();
563+
let mut store = crate::Store::init().unwrap();
564564
store.populate().unwrap();
565565

566566
let collection_page_size = store

lib/src/commit.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -807,7 +807,7 @@ mod test {
807807
#[test]
808808
fn signature_matches() {
809809
let private_key = "CapMWIhFUT+w7ANv9oCPqrHrwZpkP2JhzF9JnyT6WcI=";
810-
let store = crate::Store::init().unwrap();
810+
let mut store = crate::Store::init().unwrap();
811811
store.populate().unwrap();
812812
let agent = Agent::new_from_private_key(None, &store, private_key).unwrap();
813813
assert_eq!(

lib/src/db.rs

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ mod val_prop_sub_index;
1111

1212
use std::{
1313
collections::{HashMap, HashSet},
14-
sync::{Arc, Mutex},
14+
sync::Arc,
1515
vec,
1616
};
1717

@@ -91,7 +91,7 @@ pub struct Db {
9191
/// Function called whenever a Commit is applied.
9292
handle_commit: Option<Arc<HandleCommit>>,
9393
/// Email SMTP client for sending email.
94-
smtp_client: Option<Arc<Mutex<Transport<'static, Connected>>>>,
94+
smtp_client: Option<Arc<tokio::sync::Mutex<Transport<'static, Connected>>>>,
9595
}
9696

9797
impl Db {
@@ -364,7 +364,7 @@ impl Db {
364364
&mut self,
365365
smtp_config: crate::email::SmtpConfig,
366366
) -> AtomicResult<()> {
367-
self.smtp_client = Some(Arc::new(Mutex::new(
367+
self.smtp_client = Some(Arc::new(tokio::sync::Mutex::new(
368368
crate::email::get_smtp_client(smtp_config).await?,
369369
)));
370370
Ok(())
@@ -379,7 +379,8 @@ impl Db {
379379
"No SMTP client configured. Please call set_smtp_config first.".into(),
380380
)
381381
})?
382-
.lock()?;
382+
.lock()
383+
.await;
383384
email::send_mail(&mut client, message).await?;
384385
Ok(())
385386
}

lib/src/serialize.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -265,7 +265,7 @@ mod test {
265265

266266
#[test]
267267
fn serialize_json_ad() {
268-
let store = crate::Store::init().unwrap();
268+
let mut store = crate::Store::init().unwrap();
269269
store.populate().unwrap();
270270
let json = store
271271
.get_resource(crate::urls::AGENT)

lib/src/store.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -265,7 +265,7 @@ mod test {
265265
use crate::{agents::ForAgent, urls, Value};
266266

267267
fn init_store() -> Store {
268-
let store = Store::init().unwrap();
268+
let mut store = Store::init().unwrap();
269269
store.populate().unwrap();
270270
store
271271
}

0 commit comments

Comments
 (0)