Compare commits

..
Author SHA1 Message Date
phoenix c9d167da8d Changed name of function
swoosh Build / Check (pull_request) Successful in 31s
swoosh Build / Test Suite (pull_request) Successful in 28s
Release Tagging / release (pull_request) Successful in 1m10s
swoosh Build / Rustfmt (pull_request) Failing after 31s
swoosh Build / Clippy (pull_request) Successful in 33s
swoosh Build / build (pull_request) Successful in 33s
2026-06-04 21:06:08 -04:00
phoenix eeb46dc84d Added function to convert response to a json value 2026-06-04 21:05:11 -04:00
4 changed files with 20 additions and 9 deletions
+1 -5
View File
@@ -17,7 +17,6 @@ jobs:
- uses: actions-rust-lang/setup-rust-toolchain@v1
with:
toolchain: 1.95
- uses: Swatinem/rust-cache@v2
- run: |
mkdir -p ~/.ssh
echo "${{ secrets.MYREPO_TOKEN }}" > ~/.ssh/textsender-models_deploy_key
@@ -37,7 +36,6 @@ jobs:
- uses: actions-rust-lang/setup-rust-toolchain@v1
with:
toolchain: 1.95
- uses: Swatinem/rust-cache@v2
- run: |
mkdir -p ~/.ssh
echo "${{ secrets.MYREPO_TOKEN }}" > ~/.ssh/textsender-models_deploy_key
@@ -57,7 +55,6 @@ jobs:
- uses: actions-rust-lang/setup-rust-toolchain@v1
with:
toolchain: 1.95
- uses: Swatinem/rust-cache@v2
- run: rustup component add rustfmt
- run: |
mkdir -p ~/.ssh
@@ -78,7 +75,6 @@ jobs:
- uses: actions-rust-lang/setup-rust-toolchain@v1
with:
toolchain: 1.95
- uses: Swatinem/rust-cache@v2
- run: rustup component add clippy
- run: |
mkdir -p ~/.ssh
@@ -99,7 +95,6 @@ jobs:
- uses: actions-rust-lang/setup-rust-toolchain@v1
with:
toolchain: 1.95
- uses: Swatinem/rust-cache@v2
- run: |
mkdir -p ~/.ssh
echo "${{ secrets.MYREPO_TOKEN }}" > ~/.ssh/textsender-models_deploy_key
@@ -110,3 +105,4 @@ jobs:
ssh-add -v ~/.ssh/textsender-models_deploy_key
cargo build
Generated
+1 -1
View File
@@ -1573,7 +1573,7 @@ checksum = "13c2bddecc57b384dee18652358fb23172facb8a2c51ccc10d74c157bdea3292"
[[package]]
name = "swoosh"
version = "0.3.1"
version = "0.3.0"
dependencies = [
"base64-ng",
"const_format",
+1 -1
View File
@@ -1,6 +1,6 @@
[package]
name = "swoosh"
version = "0.3.1"
version = "0.3.0"
edition = "2024"
rust-version = "1.95"
description = "Library to send text messages"
+17 -2
View File
@@ -2,8 +2,23 @@ pub mod types;
pub async fn response_to_json(response: reqwest::Response) -> serde_json::Value {
match response.json().await {
Ok(json_body) => json_body,
Err(_err) => serde_json::Value::Null,
Ok(json_body) => {
json_body
/*
let res = jsonBody.as_str();
match serde_json::from_str(res) {
Ok(converted) => {
converted
}
Err(_err) => {
serde_json::Value::Null
}
}
*/
}
Err(_err) => {
serde_json::Value::Null
}
}
}