File tree Expand file tree Collapse file tree 2 files changed +9
-2
lines changed Expand file tree Collapse file tree 2 files changed +9
-2
lines changed Original file line number Diff line number Diff line change @@ -88,7 +88,7 @@ impl ConfigInternals for Config {
88
88
}
89
89
90
90
if let Some ( read_only) = self . read_only {
91
- if first {
91
+ if ! first {
92
92
s. push ( ',' ) ;
93
93
}
94
94
if read_only {
@@ -100,7 +100,7 @@ impl ConfigInternals for Config {
100
100
}
101
101
102
102
if let Some ( deferrable) = self . deferrable {
103
- if first {
103
+ if ! first {
104
104
s. push ( ',' ) ;
105
105
}
106
106
if deferrable {
Original file line number Diff line number Diff line change @@ -1039,6 +1039,13 @@ fn transaction_config() {
1039
1039
conn. set_transaction_config ( & config) . unwrap ( ) ;
1040
1040
}
1041
1041
1042
+ #[ test]
1043
+ fn transaction_config_one_setting ( ) {
1044
+ let conn = Connection :: connect ( "postgres://postgres@localhost" , SslMode :: None ) . unwrap ( ) ;
1045
+ conn. set_transaction_config ( & transaction:: Config :: new ( ) . read_only ( true ) ) . unwrap ( ) ;
1046
+ conn. set_transaction_config ( & transaction:: Config :: new ( ) . deferrable ( true ) ) . unwrap ( ) ;
1047
+ }
1048
+
1042
1049
#[ test]
1043
1050
fn transaction_with ( ) {
1044
1051
let conn = Connection :: connect ( "postgres://postgres@localhost" , SslMode :: None ) . unwrap ( ) ;
You can’t perform that action at this time.
0 commit comments