Skip to content

Commit cd9dcd0

Browse files
fix: canonicalize was giving error
1 parent 98a052a commit cd9dcd0

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

backend/src/routing/handlers.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -181,7 +181,7 @@ pub async fn edit(
181181
let old_filepath = state.env_vars.paths.get_path_from_slug(&old_filelink);
182182
let new_filepath = state.env_vars.paths.get_path_from_slug(&new_qp.filelink);
183183

184-
if old_filepath.canonicalize()? != new_filepath.canonicalize()? {
184+
if old_filepath != new_filepath {
185185
if let Err(e) = fs::copy(old_filepath, new_filepath).await {
186186
tracing::error!("Error copying file: {}", e);
187187

0 commit comments

Comments
 (0)