<commit_before>define(["js/data/Collection", "sprd/model/StockState"], function(Collection, StockState) {
    return Collection.inherit("sprd.collection.StockStates", {

        $modelFactory: StockState,

        isSizeAndAppearanceAvailable: function(size, appearance){
            return this.find(function(item){
                return item.$.size.$.id === size.$.id && item.$.appearance.$.id === appearance.$.id;
            }) || false;
        }
    });
});<commit_msg>DEV-61084 - Can only view detail page of one article in one session<commit_after>define(["js/data/Collection", "sprd/model/StockState"], function(Collection, StockState) {
    return Collection.inherit("sprd.collection.StockStates", {

        $modelFactory: StockState,

        isSizeAndAppearanceAvailable: function(size, appearance){

            if (!(size && appearance)) {
                return false;
            }

            return this.find(function(item){
                return item.$.size.$.id === size.$.id && item.$.appearance.$.id === appearance.$.id;
            }) || false;
        }
    });
});
{'fraction_non_alphanumeric': 0.15736505032021958, 'fraction_numerical': 0.004574565416285453, 'mean_word_length': 2.540453074433657, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '7462497', 'n_tokens_mistral': 305, 'n_tokens_neox': 290, 'n_words': 54}