improve code with clippy
This commit is contained in:
@ -124,7 +124,7 @@ pub enum LogbookCreateError {
|
||||
|
||||
impl From<LogbookUpdateError> for LogbookCreateError {
|
||||
fn from(value: LogbookUpdateError) -> Self {
|
||||
return match value {
|
||||
match value {
|
||||
LogbookUpdateError::NotYourEntry => LogbookCreateError::NotYourEntry,
|
||||
LogbookUpdateError::TooManyRowers(a, b) => LogbookCreateError::TooManyRowers(a, b),
|
||||
LogbookUpdateError::RowerCreateError(a, b) => {
|
||||
@ -140,7 +140,7 @@ impl From<LogbookUpdateError> for LogbookCreateError {
|
||||
LogbookUpdateError::UserNotAllowedToUseBoat => {
|
||||
LogbookCreateError::UserNotAllowedToUseBoat
|
||||
}
|
||||
};
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@ -429,7 +429,7 @@ ORDER BY departure DESC
|
||||
return Err(LogbookUpdateError::SteeringPersonNotInRowers);
|
||||
}
|
||||
|
||||
if !boat.shipmaster_allowed(&user).await && self.shipmaster != user.id {
|
||||
if !boat.shipmaster_allowed(user).await && self.shipmaster != user.id {
|
||||
//second part:
|
||||
//shipmaster has
|
||||
//entered a
|
||||
|
Reference in New Issue
Block a user