async def files_for_PR(gh, pull_request):
    """Get files for a pull request."""
    # For some unknown reason there isn't any files URL in a pull request
    # payload.
    files_url = f'{pull_request["url"]}/files'
    data = []
    async for filedata in gh.getiter(files_url):  # pragma: no branch
        data.append(
            {
                "file_name": filedata["filename"],
                "patch": filedata.get("patch", ""),
            }
        )
    return data