Skip to content

Commit

Permalink
Use Winter's Url facade instead of Laravel's
Browse files Browse the repository at this point in the history
  • Loading branch information
LukeTowers committed Dec 16, 2024
1 parent 09b945e commit 02c8469
Show file tree
Hide file tree
Showing 17 changed files with 18 additions and 18 deletions.
2 changes: 1 addition & 1 deletion modules/backend/helpers/Backend.php
Original file line number Diff line number Diff line change
Expand Up @@ -7,12 +7,12 @@
use Exception;
use Illuminate\Support\Facades\Redirect;
use Illuminate\Support\Facades\Request;
use Illuminate\Support\Facades\URL;
use System\Helpers\DateTime as DateTimeHelper;
use Winter\Storm\Router\Helper as RouterHelper;
use Winter\Storm\Support\Facades\Config;
use Winter\Storm\Support\Facades\File;
use Winter\Storm\Support\Facades\Html;
use Winter\Storm\Support\Facades\Url;

/**
* Backend Helper
Expand Down
2 changes: 1 addition & 1 deletion modules/backend/models/BrandSetting.php
Original file line number Diff line number Diff line change
Expand Up @@ -7,11 +7,11 @@
use Illuminate\Support\Facades\App;
use Illuminate\Support\Facades\Cache;
use Illuminate\Support\Facades\Lang;
use Illuminate\Support\Facades\URL;
use Less_Parser;
use Winter\Storm\Database\Model;
use Winter\Storm\Support\Facades\Config;
use Winter\Storm\Support\Facades\File;
use Winter\Storm\Support\Facades\Url;

/**
* Brand settings that affect all users
Expand Down
2 changes: 1 addition & 1 deletion modules/cms/controllers/Index.php
Original file line number Diff line number Diff line change
Expand Up @@ -22,13 +22,13 @@
use Exception;
use Illuminate\Support\Facades\Lang;
use Illuminate\Support\Facades\Request;
use Illuminate\Support\Facades\URL;
use System\Helpers\DateTime;
use Winter\Storm\Exception\ApplicationException;
use Winter\Storm\Router\Router as StormRouter;
use Winter\Storm\Support\Facades\Config;
use Winter\Storm\Support\Facades\Event;
use Winter\Storm\Support\Facades\Flash;
use Winter\Storm\Support\Facades\Url;

/**
* CMS index
Expand Down
2 changes: 1 addition & 1 deletion modules/cms/controllers/Themes.php
Original file line number Diff line number Diff line change
Expand Up @@ -16,12 +16,12 @@
use Illuminate\Support\Facades\Artisan;
use Illuminate\Support\Facades\Lang;
use Illuminate\Support\Facades\Redirect;
use Illuminate\Support\Facades\URL;
use System\Classes\SettingsManager;
use Winter\Storm\Exception\ApplicationException;
use Winter\Storm\Exception\ValidationException;
use Winter\Storm\Support\Facades\File;
use Winter\Storm\Support\Facades\Flash;
use Winter\Storm\Support\Facades\Url;
use Winter\Storm\Support\Str;

/**
Expand Down
2 changes: 1 addition & 1 deletion modules/cms/helpers/Cms.php
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,8 @@
namespace Cms\Helpers;

use Illuminate\Support\Facades\Route;
use Illuminate\Support\Facades\URL;
use Winter\Storm\Support\Facades\Config;
use Winter\Storm\Support\Facades\Url;

/**
* CMS Helper
Expand Down
2 changes: 1 addition & 1 deletion modules/cms/twig/FrameworkNode.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,11 +2,11 @@

namespace Cms\Twig;

use Illuminate\Support\Facades\URL;
use System\Classes\CombineAssets;
use System\Models\Parameter;
use Twig\Compiler as TwigCompiler;
use Twig\Node\Node as TwigNode;
use Winter\Storm\Support\Facades\Url;

/**
* Represents a "framework" node
Expand Down
2 changes: 1 addition & 1 deletion modules/cms/twig/SnowboardNode.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,12 +2,12 @@

namespace Cms\Twig;

use Illuminate\Support\Facades\URL;
use System\Classes\CombineAssets;
use System\Models\Parameter;
use Twig\Compiler as TwigCompiler;
use Twig\Node\Node as TwigNode;
use Winter\Storm\Support\Facades\Config;
use Winter\Storm\Support\Facades\Url;

/**
* Represents a "snowboard" node
Expand Down
2 changes: 1 addition & 1 deletion modules/cms/widgets/AssetList.php
Original file line number Diff line number Diff line change
Expand Up @@ -10,14 +10,14 @@
use Illuminate\Support\Facades\Lang;
use Illuminate\Support\Facades\Request;
use Illuminate\Support\Facades\Response;
use Illuminate\Support\Facades\URL;
use RecursiveDirectoryIterator;
use RecursiveIteratorIterator;
use Symfony\Component\HttpFoundation\File\UploadedFile;
use Winter\Storm\Exception\ApplicationException;
use Winter\Storm\Filesystem\Definitions as FileDefinitions;
use Winter\Storm\Support\Facades\File;
use Winter\Storm\Support\Facades\Input;
use Winter\Storm\Support\Facades\Url;
use Winter\Storm\Support\Str;

/**
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

use Winter\Storm\Support\Facades\Config as MyConfig;
use Illuminate\Support\Facades\Lang as MyLang;
use Winter\Storm\Support\Facades\URL;
use Winter\Storm\Support\Facades\Url;
use Winter\Storm\Support\Arr;
use Winter\Storm\Support\Facades\Yaml;

Expand Down
4 changes: 2 additions & 2 deletions modules/system/aliases.php
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@
'Session' => Illuminate\Support\Facades\Session::class,
'Storage' => Illuminate\Support\Facades\Storage::class,
// 'Str' => Illuminate\Support\Str::class, // Replaced by Winter
// 'URL' => Illuminate\Support\Facades\URL::class, // Replaced by Winter
// 'URL' => Illuminate\Support\Facades\URL::class, // Replaced by Winter
// 'Validator' => Illuminate\Support\Facades\Validator::class, // Replaced by Winter
'View' => Illuminate\Support\Facades\View::class,

Expand Down Expand Up @@ -85,7 +85,7 @@
* Backwards compatibility aliases
*/
'Db' => Winter\Storm\Support\Facades\DB::class,
'Url' => Winter\Storm\Support\Facades\URL::class,
'Url' => Winter\Storm\Support\Facades\Url::class,
'TestCase' => System\Tests\Bootstrap\TestCase::class,
'PluginTestCase' => System\Tests\Bootstrap\PluginTestCase::class,

Expand Down
2 changes: 1 addition & 1 deletion modules/system/classes/CombineAssets.php
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,6 @@
use Illuminate\Support\Facades\Request;
use Illuminate\Support\Facades\Response;
use Illuminate\Support\Facades\Route;
use Illuminate\Support\Facades\URL;
use System\Helpers\Cache as CacheHelper;
use Winter\Storm\Parse\Assetic\Cache\FilesystemCache;
use Winter\Storm\Parse\Assetic\Filter\JavascriptImporter;
Expand All @@ -26,6 +25,7 @@
use Winter\Storm\Support\Facades\Config;
use Winter\Storm\Support\Facades\Event;
use Winter\Storm\Support\Facades\File;
use Winter\Storm\Support\Facades\Url;

/**
* Combiner class used for combining JavaScript and StyleSheet files.
Expand Down
2 changes: 1 addition & 1 deletion modules/system/classes/ImageResizer.php
Original file line number Diff line number Diff line change
Expand Up @@ -6,14 +6,14 @@
use Illuminate\Support\Facades\Cache;
use Illuminate\Support\Facades\Crypt;
use Illuminate\Support\Facades\Storage;
use Illuminate\Support\Facades\URL;
use System\Models\File as SystemFileModel;
use Winter\Storm\Database\Attach\File as FileModel;
use Winter\Storm\Database\Attach\Resizer as DefaultResizer;
use Winter\Storm\Exception\SystemException;
use Winter\Storm\Support\Facades\Config;
use Winter\Storm\Support\Facades\Event;
use Winter\Storm\Support\Facades\File as FileHelper;
use Winter\Storm\Support\Facades\Url;

/**
* Image Resizing class used for resizing any image resources accessible
Expand Down
2 changes: 1 addition & 1 deletion modules/system/classes/MediaLibrary.php
Original file line number Diff line number Diff line change
Expand Up @@ -6,11 +6,11 @@
use Illuminate\Support\Facades\Cache;
use Illuminate\Support\Facades\Lang;
use Illuminate\Support\Facades\Storage;
use Illuminate\Support\Facades\URL;
use Winter\Storm\Exception\ApplicationException;
use Winter\Storm\Exception\SystemException;
use Winter\Storm\Filesystem\Definitions as FileDefinitions;
use Winter\Storm\Support\Facades\Config;
use Winter\Storm\Support\Facades\Url;
use Winter\Storm\Support\Str;
use Winter\Storm\Support\Svg;

Expand Down
2 changes: 1 addition & 1 deletion modules/system/classes/UpdateManager.php
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,6 @@
use Illuminate\Support\Facades\App;
use Illuminate\Support\Facades\Cache;
use Illuminate\Support\Facades\Lang;
use Illuminate\Support\Facades\URL;
use System\Helpers\Cache as CacheHelper;
use System\Models\Parameter;
use System\Models\PluginVersion;
Expand All @@ -20,6 +19,7 @@
use Winter\Storm\Support\Facades\File;
use Winter\Storm\Support\Facades\Http;
use Winter\Storm\Support\Facades\Schema;
use Winter\Storm\Support\Facades\Url;

/**
* Update manager
Expand Down
2 changes: 1 addition & 1 deletion modules/system/models/File.php
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,9 @@

use Backend\Controllers\Files;
use Illuminate\Support\Facades\Storage;
use Illuminate\Support\Facades\URL;
use Winter\Storm\Database\Attach\File as FileBase;
use Winter\Storm\Support\Facades\Config;
use Winter\Storm\Support\Facades\Url;

/**
* File attachment model
Expand Down
2 changes: 1 addition & 1 deletion modules/system/tests/classes/ImageResizerTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -6,14 +6,14 @@
use Cms\Classes\Controller as CmsController;
use Cms\Classes\Theme;
use DMS\PHPUnitExtensions\ArraySubset\ArraySubsetAsserts;
use Illuminate\Support\Facades\URL;
use System\Classes\ImageResizer;
use System\Classes\MediaLibrary;
use System\Models\File as FileModel;
use System\Tests\Bootstrap\PluginTestCase;
use Winter\Storm\Exception\SystemException;
use Winter\Storm\Support\Facades\Config;
use Winter\Storm\Support\Facades\Event;
use Winter\Storm\Support\Facades\Url;

class ImageResizerTest extends PluginTestCase
{
Expand Down
2 changes: 1 addition & 1 deletion modules/system/twig/Extension.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,13 +2,13 @@

namespace System\Twig;

use Illuminate\Support\Facades\URL;
use System\Classes\ImageResizer;
use System\Classes\MarkupManager;
use System\Classes\MediaLibrary;
use Twig\Extension\AbstractExtension as TwigExtension;
use Twig\TwigFilter as TwigSimpleFilter;
use Twig\TwigFunction as TwigSimpleFunction;
use Winter\Storm\Support\Facades\Url;

/**
* The System Twig extension class implements common Twig functions and filters.
Expand Down

0 comments on commit 02c8469

Please sign in to comment.