From 0296977d6cb115b2d8af16ae6e9f1aaebedba8f3 Mon Sep 17 00:00:00 2001 From: Ruben Sousa Date: Fri, 30 Aug 2024 12:10:31 +0200 Subject: [PATCH] Use removeLastOrNull --- .../com/rubensousa/dpadrecyclerview/testing/DpadTestAdapter.kt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/dpadrecyclerview-testing/src/androidTest/java/com/rubensousa/dpadrecyclerview/testing/DpadTestAdapter.kt b/dpadrecyclerview-testing/src/androidTest/java/com/rubensousa/dpadrecyclerview/testing/DpadTestAdapter.kt index 55c36571..c4dd2b36 100644 --- a/dpadrecyclerview-testing/src/androidTest/java/com/rubensousa/dpadrecyclerview/testing/DpadTestAdapter.kt +++ b/dpadrecyclerview-testing/src/androidTest/java/com/rubensousa/dpadrecyclerview/testing/DpadTestAdapter.kt @@ -79,7 +79,7 @@ class DpadTestAdapter( } fun removeItem() { - items.removeLast() + items.removeLastOrNull() notifyItemRemoved(items.size) }