Skip to content

Commit

Permalink
Fixed delete request
Browse files Browse the repository at this point in the history
  • Loading branch information
Flowneee committed Aug 20, 2023
1 parent c385cdb commit d48ba90
Show file tree
Hide file tree
Showing 5 changed files with 8 additions and 8 deletions.
3 changes: 3 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,9 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
### Added
- `TupleResponse` type for decoding `eval` and `call` responses.

### Fixed
- `delete` request sends correct request type.


## [0.0.5] - 2023-08-05
### Added
Expand Down
8 changes: 2 additions & 6 deletions examples/schema.rs
Original file line number Diff line number Diff line change
Expand Up @@ -17,15 +17,11 @@ async fn main() -> Result<(), anyhow::Error> {
.select::<(i64, String), _>(None, None, Some(IteratorType::All), ())
.await?
);
space.upsert(("=",), (1, "Second")).await?;
space.upsert((0, "Name"), ("=",)).await?;
space
.update(
(0,),
(Value::Array(vec![
"=".into(),
1.into(),
"Second (updated)".into(),
]),),
(Value::Array(vec!["=".into(), 1.into(), "Second".into()]),),
)
.await?;
info!(
Expand Down
2 changes: 1 addition & 1 deletion src/codec/request/delete.rs
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ impl<T: Tuple> Request for Delete<T> {
where
Self: Sized,
{
RequestType::Replace
RequestType::Delete
}

// NOTE: `&mut buf: mut` is required since I don't get why compiler complain
Expand Down
1 change: 1 addition & 0 deletions src/codec/response/call.rs
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
pub struct CallResponse(rmpv::Value);
2 changes: 1 addition & 1 deletion src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
//
// Other
//
// * [ ] check or remove all unsafes, unwrap, panic, expect
// * [ ] check or remove all unsafes, panic
// * [ ] tests
// * [ ] bump version to 0.1.0
// * [ ] remove unused dependencies
Expand Down

0 comments on commit d48ba90

Please sign in to comment.