mirror of
				https://github.com/InsanusMokrassar/MicroUtils.git
				synced 2025-10-30 19:50:31 +00:00 
			
		
		
		
	fix for lastIndex in reversing of pagination
This commit is contained in:
		| @@ -19,7 +19,7 @@ fun Pagination.reverse(datasetSize: Long): SimplePagination { | |||||||
|             newPage, |             newPage, | ||||||
|             size |             size | ||||||
|         ).let { |         ).let { | ||||||
|             if (it.lastIndex > datasetSize) { |             if (it.lastIndex >= datasetSize) { | ||||||
|                 it.copy(size = (datasetSize - firstIndex - 1).toInt()) |                 it.copy(size = (datasetSize - firstIndex - 1).toInt()) | ||||||
|             } else { |             } else { | ||||||
|                 it |                 it | ||||||
|   | |||||||
		Reference in New Issue
	
	Block a user