diff --git a/erpnext/stock/doctype/batch/test_batch.py b/erpnext/stock/doctype/batch/test_batch.py
index a5dd4ac..cd621cc 100644
--- a/erpnext/stock/doctype/batch/test_batch.py
+++ b/erpnext/stock/doctype/batch/test_batch.py
@@ -153,8 +153,6 @@
 
 	def test_get_batch_qty(self):
 		'''Test getting batch quantities by batch_numbers, item_code or warehouse'''
-		from erpnext.stock.doctype.batch.batch import get_batch_qty
-
 		self.make_batch_item('ITEM-BATCH-2')
 		self.make_new_batch_and_entry('ITEM-BATCH-2', 'batch a', '_Test Warehouse - _TC')
 		self.make_new_batch_and_entry('ITEM-BATCH-2', 'batch b', '_Test Warehouse - _TC')
diff --git a/erpnext/stock/doctype/stock_entry/stock_entry.js b/erpnext/stock/doctype/stock_entry/stock_entry.js
index c7e2426..2c96541 100644
--- a/erpnext/stock/doctype/stock_entry/stock_entry.js
+++ b/erpnext/stock/doctype/stock_entry/stock_entry.js
@@ -549,11 +549,11 @@
 erpnext.stock.select_batch_and_serial_no = (frm, d = undefined) => {
 	let get_warehouse = (item) => {
 		if(frm.fields_dict.from_warehouse.disp_status === "Write") {
-			value = cstr(item.s_warehouse) || ''
-			return ['Source Warehouse', value]
+			var value = cstr(item.s_warehouse) || '';
+			return ['Source Warehouse', value];
 		} else {
-			value = cstr(item.t_warehouse) || ''
-			return ['Target Warehouse', value]
+			var value = cstr(item.t_warehouse) || '';
+			return ['Target Warehouse', value];
 		}
 	}
 
@@ -566,11 +566,11 @@
 			},
 			callback: (r) => {
 				if (r.message) {
-					batch_rows_by_oldest = [];
+					var batch_rows_by_oldest = [];
 					if(warehouse_details[0] === 'Source Warehouse') {
-						qty = total_qty;
+						var qty = total_qty;
 						for(var i = 0; i < r.message.length; i++) {
-							batch_row = {name: 'batch 1'};
+							var batch_row = {name: 'batch 1'};
 							batch_row.batch_no = r.message[i].batch_no;
 							batch_row.available_qty = r.message[i].qty;
 							if (parseInt(qty) <= parseInt(r.message[i].qty)) {
@@ -602,7 +602,7 @@
 erpnext.stock.show_batch_serial_modal = (frm, item, item_code, qty, warehouse_details,
 	has_batch, oldest = undefined) => {
 
-	let data = oldest ? oldest : []
+	let data = oldest ? oldest : [];
 	let title = "";
 	let fields = [
 		{fieldname: 'item_code', read_only: 1, fieldtype:'Link', options: 'Item',
@@ -650,7 +650,7 @@
 			},
 			{fieldtype: 'Column Break'},
 			{fieldname: 'serial_no', fieldtype: 'Small Text'}
-		])
+		]);
 	}
 
 	let dialog = new frappe.ui.Dialog({
@@ -746,7 +746,7 @@
 			});
 			qty_field.set_input(total_qty);
 		} else {
-			serial_numbers = serial_no_list_field.get_value().replace(/\n/g, ' ').match(/\S+/g) || [];
+			var serial_numbers = serial_no_list_field.get_value().replace(/\n/g, ' ').match(/\S+/g) || [];
 			qty_field.set_input(serial_numbers.length);
 		}
 	}
@@ -773,7 +773,7 @@
 
 	if(serial_no_link) {
 		let serial_list = [];
-		serial_no_link.$input.on('awesomplete-selectcomplete', function(e) {
+		serial_no_link.$input.on('awesomplete-selectcomplete', function() {
 			if(serial_no_link.get_value().length > 0) {
 				let new_no = serial_no_link.get_value();
 				let list_value = serial_no_list_field.get_value();
@@ -802,7 +802,7 @@
 
 	if(batches_field) {
 		batches_field.grid.add_new_row(null, null, true);
-		batches_field.grid.wrapper.on('change', 'input[data-fieldname="selected_qty"]', function(e) {
+		batches_field.grid.wrapper.on('change', 'input[data-fieldname="selected_qty"]', function() {
 			// check if batch is selected
 			if($(this).val().length !== 0) {
 				let $row = $(this).closest('.grid-row');
@@ -825,7 +825,7 @@
 			}
 
 		});
-		batches_field.grid.wrapper.on('change', 'input[data-fieldname="batch_no"]', function(e) {
+		batches_field.grid.wrapper.on('change', 'input[data-fieldname="batch_no"]', function() {
 			let $row = $(this).closest('.grid-row');
 			let name = $row.attr('data-name');
 			let row = batches_field.grid.grid_rows_by_docname[name];
@@ -839,20 +839,20 @@
 			}
 		});
 
-		batches_field.grid.wrapper.on('change', function(e) {
+		batches_field.grid.wrapper.on('change', function() {
 			update_quantity(1);
 		});
 
-		batches_field.grid.wrapper.on('change', 'input', function(e) {
+		batches_field.grid.wrapper.on('change', 'input', function() {
 			let fieldname = $(this).attr('data-fieldname');
 			let $row = $(this).closest('.grid-row');
 			let name = $row.attr('data-name');
 			let row = batches_field.grid.grid_rows_by_docname[name];
 
-			field = row.on_grid_fields_dict[fieldname];
+			var field = row.on_grid_fields_dict[fieldname];
 			field.$input.trigger('blur');
 			row.doc[fieldname] = field.get_value();
-			batches_field.grid.set_value(fieldname, row.doc[fieldname], row.doc)
+			batches_field.grid.set_value(fieldname, row.doc[fieldname], row.doc);
 		});
 
 		warehouse_field.$input.on('change', function() {
