Skip to content

Commit 47fd9f6

Browse files
committed
fix: remove TinyMceAdapter
1 parent 2d2beb0 commit 47fd9f6

File tree

4 files changed

+14
-25
lines changed

4 files changed

+14
-25
lines changed

_config/assets.yml

Lines changed: 1 addition & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ Name: silverstripe-azure-flysystem
33
Only:
44
envvarset: AZURE_CONNECTION_URL
55
After:
6-
- '#assetsflysystem'
6+
- assetsflysystem
77
---
88
SilverStripe\Core\Injector\Injector:
99
FullscreenInteractive\SilverStripe\AzureStorage\Adapter\PublicAdapter:
@@ -35,16 +35,3 @@ SilverStripe\Core\Injector\Injector:
3535
constructor:
3636
adapter: '%$FullscreenInteractive\SilverStripe\AzureStorage\Adapter\ProtectedAdapter'
3737
cache: '%$League\Flysystem\Cached\Storage\Adapter.protected'
38-
League\Flysystem\Filesystem.tinymce:
39-
class: 'League\Flysystem\Filesystem'
40-
constructor:
41-
FilesystemAdapter: '%$FullscreenInteractive\SilverStripe\AzureStorage\Adapter\TinyMceAdapter'
42-
FilesystemConfig:
43-
visibility: public
44-
TinyMCEGeneratedAssetHandler:
45-
class: 'SilverStripe\Assets\Flysystem\GeneratedAssets'
46-
properties:
47-
Filesystem: '%$League\Flysystem\Filesystem.tinymce'
48-
SilverStripe\Forms\HTMLEditor\TinyMCECombinedGenerator:
49-
properties:
50-
AssetHandler: '%$TinyMCEGeneratedAssetHandler'

src/Adapter/DBCache.php

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@
55
use Exception;
66
use FullscreenInteractive\SilverStripe\AzureStorage\Model\BlobCache;
77
use League\Flysystem\Cached\Storage\AbstractCache;
8+
use League\Flysystem\Util;
89

910
class DBCache extends AbstractCache
1011
{
@@ -52,6 +53,15 @@ public function load()
5253
}
5354
}
5455

56+
public function has($path)
57+
{
58+
if (strpos($path, '_tinymce') !== false) {
59+
return false;
60+
}
61+
62+
return parent::has($path);
63+
}
64+
5565
/**
5666
* @throws Exception
5767
*/

src/Adapter/PublicCachedAdapter.php

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,8 @@ class PublicCachedAdapter extends CachedAdapter implements PublicAdapter
99
{
1010
public function getPublicUrl($path)
1111
{
12-
return $this->getAdapter()->getPublicUrl($path);
12+
$url = $this->getAdapter()->getPublicUrl($path);
13+
14+
return $url;
1315
}
1416
}

src/Adapter/TinyMceAdapter.php

Lines changed: 0 additions & 10 deletions
This file was deleted.

0 commit comments

Comments
 (0)