handle None case in `update_reserved_qty_for_production` (#11593)

diff --git a/erpnext/stock/doctype/bin/bin.py b/erpnext/stock/doctype/bin/bin.py
index 9b49b69..626a9db 100644
--- a/erpnext/stock/doctype/bin/bin.py
+++ b/erpnext/stock/doctype/bin/bin.py
@@ -88,10 +88,11 @@
 				and item.source_warehouse = %s
 				and pro.status not in ("Stopped", "Completed")''', (self.item_code, self.warehouse))[0][0]
 
-		self.set_projected_qty()
+		if self.reserved_qty_for_production:
+			self.set_projected_qty()
 
-		self.db_set('reserved_qty_for_production', self.reserved_qty_for_production)
-		self.db_set('projected_qty', self.projected_qty)
+			self.db_set('reserved_qty_for_production', self.reserved_qty_for_production)
+			self.db_set('projected_qty', self.projected_qty)
 
 
 def update_item_projected_qty(item_code):