def filter_by_symbol(self, array, symbol=None):
    array = self.to_array(array)
    if symbol:
        return [entry for entry in array if (entry['symbol'] == symbol)]
    return array
def filter_by_symbol(self, array, symbol=None):
    array = self.to_array(array)
    if symbol:
        return [entry for entry in array if (entry['symbol'] == symbol)]
    return array