source/Application/Model/OrderFile.php
public function isValid()
    {
        if (!$this->oxorderfiles__oxmaxdownloadcount->value || ($this->oxorderfiles__oxdownloadcount->value < $this->oxorderfiles__oxmaxdownloadcount->value)) {
            if (!$this->oxorderfiles__oxlinkexpirationtime->value && !$this->oxorderfiles__oxdownloadxpirationtime->value) {
                return true;
            } else {
                $sNow = \OxidEsales\Eshop\Core\Registry::getUtilsDate()->getTime();
                $iTimestamp = strtotime($this->oxorderfiles__oxvaliduntil->value);
                if (!$iTimestamp || ($iTimestamp > $sNow)) {
                    return true;
                }
            }
        }

        return false;
    }
public function isValid()
    {
        if (!$this->oxorderfiles__oxmaxdownloadcount->value || ($this->oxorderfiles__oxdownloadcount->value < $this->oxorderfiles__oxmaxdownloadcount->value)) {
            if (!$this->oxorderfiles__oxlinkexpirationtime->value && !$this->oxorderfiles__oxdownloadxpirationtime->value) {
                return true;
            } else {
                $sNow = \OxidEsales\Eshop\Core\Registry::getUtilsDate()->getTime();
                $iTimestamp = strtotime($this->oxorderfiles__oxvaliduntil->value);
                if (!$iTimestamp || ($iTimestamp > $sNow)) {
                    return true;
                }
            }
        }

        return false;
    }
public function isValid ( ) { if ( ! $ this -> oxorderfiles__oxmaxdownloadcount -> value || ( $ this -> oxorderfiles__oxdownloadcount -> value < $ this -> oxorderfiles__oxmaxdownloadcount -> value ) ) { if ( ! $ this -> oxorderfiles__oxlinkexpirationtime -> value && ! $ this -> oxorderfiles__oxdownloadxpirationtime -> value ) { return true ; } else { $ sNow = \ OxidEsales \ Eshop \ Core \ Registry :: getUtilsDate ( ) -> getTime ( ) ; $ iTimestamp = strtotime ( $ this -> oxorderfiles__oxvaliduntil -> value ) ; if ( ! $ iTimestamp || ( $ iTimestamp > $ sNow ) ) { return true ; } } } return false ; }
Checks if order file is still available to download

@return bool
Checks if order file is still available to download