Skip to content

Commit 06f4156

Browse files
Merge pull request #1694 from HTGAzureX1212/nightly
Fix Compiler Errors
2 parents 0869fb0 + 84e8073 commit 06f4156

File tree

1 file changed

+5
-5
lines changed
  • api-backend/hartex-backend-models/src

1 file changed

+5
-5
lines changed

api-backend/hartex-backend-models/src/lib.rs

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -34,13 +34,13 @@ use serde::Deserialize;
3434
///
3535
/// This is the object returned by a certain API endpoint.
3636
#[derive(Deserialize)]
37-
pub struct Response<'a, T> {
37+
pub struct Response<T> {
3838
code: u16,
39-
message: &'a str,
39+
message: String,
4040
data: T,
4141
}
4242

43-
impl<'a, T> Response<'a, T>
43+
impl<'a, T> Response<T>
4444
where
4545
T: Clone + Deserialize<'a>,
4646
{
@@ -50,8 +50,8 @@ where
5050
}
5151

5252
/// The message of the response.
53-
pub fn message(&self) -> &'a str {
54-
self.message
53+
pub fn message(&self) -> String {
54+
self.message.clone()
5555
}
5656

5757
/// The data of the response.

0 commit comments

Comments
 (0)