<?php
/**
 * ------------------------ 
 *  版权所有  www.tecmz.com
 *  商业版本请购买正版授权使用
 * ------------------------
*/ namespace ModStart\Core\Assets\Driver; use ModStart\Core\Assets\AssetsPath; use Illuminate\Support\Facades\Cache; class LocalAssetsPath implements AssetsPath { const CACHE_PREFIX = 'modstart:asset-file:'; public function getPathWithHash($fWBvH) { goto bc6rg; k53rk: if ('&' == $H8dqo) { $Yhv92 = substr($fWBvH, 0, strpos($fWBvH, '?')); } goto Y_SAX; vcG9T: $Yhv92 = $fWBvH; goto k53rk; Y_SAX: if (file_exists($Yhv92)) { goto gX920; Kna2a: Cache::put($ZocKV, $Ooi_1, 0); goto SdDQH; SdDQH: return $fWBvH . $H8dqo . $Ooi_1; goto Ij1m8; gX920: $Ooi_1 = '' . crc32(md5_file($Yhv92)); goto Kna2a; Ij1m8: } goto wBqAj; bc6rg: $Ooi_1 = Cache::get($ZocKV = self::CACHE_PREFIX . $fWBvH, null); goto twVUg; HpKeA: if (null !== $Ooi_1) { return $fWBvH . $H8dqo . $Ooi_1; } goto vcG9T; twVUg: $H8dqo = false === strpos($fWBvH, '?') ? '?' : '&'; goto HpKeA; wBqAj: Cache::put($ZocKV, '', 0); goto V0Vvj; V0Vvj: return $fWBvH; goto vbq2O; vbq2O: } public function getCDN($fWBvH) { return config('modstart.asset.cdn'); } }