# yatra/3.0.8/app/Upgrades/AbstractUpgradeStep.php

Yatra – Travel Booking &amp; Tour Operator Software, version 3.0.8. 20 lines.

- Page: https://pluginprobe.com/plugins/yatra/3.0.8/code/app/Upgrades/AbstractUpgradeStep.php
- Raw: https://pluginprobe.com/plugins/yatra/3.0.8/raw/app/Upgrades/AbstractUpgradeStep.php
- Modified: 2026-05-04T10:23:44+00:00

Line numbers below start at 1. Link to a line or a range by appending a fragment to the
page URL, for example `https://pluginprobe.com/plugins/yatra/3.0.8/code/app/Upgrades/AbstractUpgradeStep.php#L10-L20`.

```php
<?php

declare(strict_types=1);

namespace Yatra\Upgrades;

use Yatra\Upgrades\Contracts\UpgradeStepInterface;

/**
 * Default {@see UpgradeStepInterface::shouldApply()}: run only when crossing this target from below.
 */
abstract class AbstractUpgradeStep implements UpgradeStepInterface
{
    public static function shouldApply(string $fromVersion, string $toVersion): bool
    {
        return version_compare($fromVersion, static::targetVersion(), '<')
            && version_compare($toVersion, static::targetVersion(), '>=');
    }
}

```
