<?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($RLMU5) { goto LFu4K; AOAEy: $RvnUw = $RLMU5; goto Jfx9d; Jfx9d: if ('&' == $g63oj) { $RvnUw = substr($RLMU5, 0, strpos($RLMU5, '?')); } goto fjrIu; dkyjT: return $RLMU5; goto u3qkY; fjrIu: if (file_exists($RvnUw)) { goto Cpczs; HT32d: return $RLMU5 . $g63oj . $THL2f; goto qZ82z; uEUTt: Cache::put($ZjtSD, $THL2f, 0); goto HT32d; Cpczs: $THL2f = '' . crc32(md5_file($RvnUw)); goto uEUTt; qZ82z: } goto cxv4J; cxv4J: Cache::put($ZjtSD, '', 0); goto dkyjT; Zipis: $g63oj = false === strpos($RLMU5, '?') ? '?' : '&'; goto ZWxp9; LFu4K: $THL2f = Cache::get($ZjtSD = self::CACHE_PREFIX . $RLMU5, null); goto Zipis; ZWxp9: if (null !== $THL2f) { return $RLMU5 . $g63oj . $THL2f; } goto AOAEy; u3qkY: } public function getCDN($RLMU5) { return config('modstart.asset.cdn'); } }