src/Asset/File.php
protected function _findSource()
    {
        $path = $this->_manager->getPath();

        if ($path->isVirtual($this->_source)) {
            $path = $path->get($this->_source);

            $isStrictMode = $this->_manager->getParams()->get('strict_mode', false, 'bool');
            if ($isStrictMode && !$path) {
                throw new Exception("Asset file not found: {$this->_source}");
            }

            return $path;
        }

        if (Url::isAbsolute($this->_source)) {
            return $this->_source;
        }

        $fullPath = $path->get('root:' . $this->_source);

        return $fullPath;
    }
protected function _findSource()
    {
        $path = $this->_manager->getPath();

        if ($path->isVirtual($this->_source)) {
            $path = $path->get($this->_source);

            $isStrictMode = $this->_manager->getParams()->get('strict_mode', false, 'bool');
            if ($isStrictMode && !$path) {
                throw new Exception("Asset file not found: {$this->_source}");
            }

            return $path;
        }

        if (Url::isAbsolute($this->_source)) {
            return $this->_source;
        }

        $fullPath = $path->get('root:' . $this->_source);

        return $fullPath;
    }
protected function _findSource ( ) { $ path = $ this -> _manager -> getPath ( ) ; if ( $ path -> isVirtual ( $ this -> _source ) ) { $ path = $ path -> get ( $ this -> _source ) ; $ isStrictMode = $ this -> _manager -> getParams ( ) -> get ( 'strict_mode' , false , 'bool' ) ; if ( $ isStrictMode && ! $ path ) { throw new Exception ( "Asset file not found: {$this->_source}" ) ; } return $ path ; } if ( Url :: isAbsolute ( $ this -> _source ) ) { return $ this -> _source ; } $ fullPath = $ path -> get ( 'root:' . $ this -> _source ) ; return $ fullPath ; }
Find source in variants.

@return string|array
@throws Exception
Find source in variants .