Write a Python function to flatten a nested list of lists into a single list containing all elements.
nested_list = [[1, 2], [3, 4], [5, 6]]
def flatten_list(nested_list):
    return [item for sublist in nested_list for item in sublist]