fix: Prevent clearing of Depreciation Schedule on adding more than one Finance Book
diff --git a/erpnext/assets/doctype/asset/asset.py b/erpnext/assets/doctype/asset/asset.py
index c0c437f..7031ed1 100644
--- a/erpnext/assets/doctype/asset/asset.py
+++ b/erpnext/assets/doctype/asset/asset.py
@@ -185,11 +185,11 @@
if not self.available_for_use_date:
return
+ start = self.clear_depreciation_schedule()
+
for d in self.get('finance_books'):
self.validate_asset_finance_books(d)
- start = self.clear_depreciation_schedule()
-
# value_after_depreciation - current Asset value
if self.docstatus == 1 and d.value_after_depreciation:
value_after_depreciation = (flt(d.value_after_depreciation) -