<commit_before><?php

namespace League\Glide\Manipulators;

use Intervention\Image\Image;

/**
 * @property string $or
 */
class Flip extends BaseManipulator
{
    /**
     * Perform flip image manipulation.
     * @param  Image $image The source image.
     * @return Image The manipulated image.
     */
    public function run(Image $image)
    {
        if ($flip = $this->getFlip()) {
            if ($flip === 'all') {
                return $image->flip('h')->flip('v');
            }

            return $image->flip($flip);
        }

        return $image;
    }

    /**
     * Resolve flip.
     * @return string The resolved flip.
     */
    public function getFlip()
    {
        if (in_array($this->flip, ['h', 'v', 'all'], true)) {
            return $this->flip;
        }
    }
}
<commit_msg>Correct usage of both<commit_after><?php

namespace League\Glide\Manipulators;

use Intervention\Image\Image;

/**
 * @property string $or
 */
class Flip extends BaseManipulator
{
    /**
     * Perform flip image manipulation.
     * @param  Image $image The source image.
     * @return Image The manipulated image.
     */
    public function run(Image $image)
    {
        if ($flip = $this->getFlip()) {
            if ($flip === 'both') {
                return $image->flip('h')->flip('v');
            }

            return $image->flip($flip);
        }

        return $image;
    }

    /**
     * Resolve flip.
     * @return string The resolved flip.
     */
    public function getFlip()
    {
        if (in_array($this->flip, ['h', 'v', 'both'], true)) {
            return $this->flip;
        }
    }
}

{'fraction_non_alphanumeric': 0.15055079559363524, 'fraction_numerical': 0.0, 'mean_word_length': 1.8189655172413792, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 15, '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': '4110572', 'n_tokens_mistral': 521, 'n_tokens_neox': 491, 'n_words': 125}