Skip to content

Commit 974c33d

Browse files
rebasedmingkysshsy
authored andcommitted
change function signatures
1 parent bce44e1 commit 974c33d

File tree

4 files changed

+6
-6
lines changed

4 files changed

+6
-6
lines changed

supabase-wrappers/src/instance.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -81,6 +81,6 @@ pub(super) unsafe fn create_fdw_instance_from_table_id<
8181
false => HashMap::new(),
8282
};
8383

84-
let wrapper = W::new(&fserver_opts, &user_mapping_opts);
84+
let wrapper = W::new(fserver_opts, user_mapping_opts);
8585
wrapper.report_unwrap()
8686
}

supabase-wrappers/src/interface.rs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -654,8 +654,8 @@ pub trait ForeignDataWrapper<E: Into<ErrorReport>> {
654654
/// info or API url in an variable, but don't do heavy works like database
655655
/// connection or API call.
656656
fn new(
657-
server_options: &HashMap<String, String>,
658-
user_mapping_options: &HashMap<String, String>,
657+
server_options: HashMap<String, String>,
658+
user_mapping_options: HashMap<String, String>,
659659
) -> Result<Self, E>
660660
where
661661
Self: Sized;
@@ -692,7 +692,7 @@ pub trait ForeignDataWrapper<E: Into<ErrorReport>> {
692692
columns: &[Column],
693693
sorts: &[Sort],
694694
limit: &Option<Limit>,
695-
options: &HashMap<String, String>,
695+
options: HashMap<String, String>,
696696
) -> Result<(), E>;
697697

698698
/// Called when fetch one row from the foreign source

supabase-wrappers/src/options.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -95,7 +95,7 @@ pub fn check_options_contain(opt_list: &[Option<String>], tgt: &str) -> Result<(
9595
}
9696

9797
// convert options definition to hashmap
98-
pub(super) unsafe fn options_to_hashmap(
98+
pub unsafe fn options_to_hashmap(
9999
options: *mut pg_sys::List,
100100
) -> Result<HashMap<String, String>, OptionsError> {
101101
let mut ret = HashMap::new();

supabase-wrappers/src/scan.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -87,7 +87,7 @@ impl<E: Into<ErrorReport>, W: ForeignDataWrapper<E>> FdwState<E, W> {
8787
&self.tgts,
8888
&self.sorts,
8989
&self.limit,
90-
&self.opts,
90+
self.opts.clone(),
9191
)
9292
}
9393

0 commit comments

Comments
 (0)