Provide a solution for finding duplicates in an array of integers.
Given a list of integers, return each value that appears more than once, including each duplicate only once. Preserve the order in which values are first detected as duplicates. Return an empty list when no value is repeated.
def find_duplicates(nums):