diff options
author | Santo Cariotti <santo@dcariotti.me> | 2021-03-18 12:18:19 +0100 |
---|---|---|
committer | Santo Cariotti <santo@dcariotti.me> | 2021-03-18 12:18:19 +0100 |
commit | 7bdd6d8f2d18022c34986a6eea4620d8eb6dcb3a (patch) | |
tree | c3718080abcbe0a6cc52735bcc6726952c6494a8 | |
parent | 214137b65413daff684cfe8df4d544ea0cb78516 (diff) |
fix: handle error for commit creation on repos
-rw-r--r-- | src/repository/models.rs | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/repository/models.rs b/src/repository/models.rs index 5b7b445..de82d45 100644 --- a/src/repository/models.rs +++ b/src/repository/models.rs @@ -225,7 +225,7 @@ impl Repository { let commits_result = Commit::create(pool.clone(), commits).await; if let Err(e) = commits_result { - panic!("{}", e); + return Err(e); } Ok(repo) |