mixedListToCardList(mixed, locations = 'any') {
        if(!mixed) {
            return [];
        }
        // Yank all the non-string cards
        var cardList = _.reject(mixed, card => _.isString(card));
        mixed = _.filter(mixed, card => _.isString(card));
        // Find cards objects for the rest
        _.each(mixed, (card) => {
            //Find only those cards that aren't already in the list
            var cardObject = this.filterCardsByName(card, locations).find(card => !_.contains(cardList, card));
            if(!cardObject) {
                throw new Error (`Could not find card named ${card}`);
            }
            cardList.push(cardObject);
        });

        return cardList;
    }
/**
     * Converts a mixed list of card objects and card names to a list of card objects
     * @param {(DrawCard|String)[]} mixed - mixed list of cards and names or ids
     * @param {String[]|String} locations - list of locations to get card objects from
     */
Converts a mixed list of card objects and card names to a list of card objects
@param {(DrawCard|String)[]} mixed - mixed list of cards and names or ids
@param {String[]|String} locations - list of locations to get card objects from
Converts a mixed list of card objects and card names to a list of card objects @param { ( DrawCard|String ) [] } mixed - mixed list of cards and names or ids @param { String [] |String } locations - list of locations to get card objects from
mixedListToCardList(mixed, locations = 'any') {
        if(!mixed) {
            return [];
        }
        var cardList = _.reject(mixed, card => _.isString(card));
        mixed = _.filter(mixed, card => _.isString(card));
        _.each(mixed, (card) => {
            var cardObject = this.filterCardsByName(card, locations).find(card => !_.contains(cardList, card));
            if(!cardObject) {
                throw new Error (`Could not find card named ${card}`);
            }
            cardList.push(cardObject);
        });
        return cardList;
    }
mixedListToCardList ( mixed , locations = 'any' ) { if ( ! mixed ) { return [ ] ; } var cardList = _ . reject ( mixed , card => _ . isString ( card ) ) ; mixed = _ . filter ( mixed , card => _ . isString ( card ) ) ; _ . each ( mixed , ( card ) => { var cardObject = this . filterCardsByName ( card , locations ) . find ( card => ! _ . contains ( cardList , card ) ) ; if ( ! cardObject ) { throw new Error ( ` ${ card } ` ) ; } cardList . push ( cardObject ) ; } ) ; return cardList ; }
Converts a mixed list of card objects and card names to a list of card objects
 @param {(DrawCard|String)[]} mixed - mixed list of cards and names or ids
 @param {String[]|String} locations - list of locations to get card objects from
Converts a mixed list of card objects and card names to a list of card objects @param { ( DrawCard|String ) [] } mixed - mixed list of cards and names or ids @param { String [] |String } locations - list of locations to get card objects from
// Yank all the non-string cards // Find cards objects for the rest //Find only those cards that aren't already in the list