def _set_current_page(self, current_page, last_page):
        """
        Get the current page for the request.

        :param current_page: The current page of results
        :type current_page: int

        :param last_page: The last page of results
        :type last_page: int

        :rtype: int
        """
        if not current_page:
            current_page = self.resolve_current_page()

        if current_page > last_page:
            if last_page == 0:
                return last_page

            return 1

        if not self._is_valid_page_number(current_page):
            return 1

        return current_page
dataset/ETHPy150Open sdispater/orator/orator/pagination/length_aware_paginator.py/LengthAwarePaginator._set_current_page/operator `>` -> `==`