Ramesh-vani commited on
Commit
8d841e9
·
verified ·
1 Parent(s): d70c457

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +2 -2
app.py CHANGED
@@ -134,11 +134,11 @@ async def rename_item(websocket, key,project_name, path,rpath,new_name,root, con
134
 
135
  old_path = os.path.join(os.getcwd(),'projects', key,project_name, rpath)
136
  new_name = new_name
137
-
138
  try:
139
  if os.path.exists(old_path):
140
  # Determine the new path
141
- new_path = os.path.join(os.path.dirname(old_path), new_name)
142
 
143
  # Rename the file or folder
144
  os.rename(old_path, new_path)
 
134
 
135
  old_path = os.path.join(os.getcwd(),'projects', key,project_name, rpath)
136
  new_name = new_name
137
+ new_path = os.path.join(os.path.dirname(old_path), new_name)
138
  try:
139
  if os.path.exists(old_path):
140
  # Determine the new path
141
+
142
 
143
  # Rename the file or folder
144
  os.rename(old_path, new_path)