mirror of
https://github.com/alchemy-fr/Phraseanet.git
synced 2025-10-12 20:43:25 +00:00
Merge branch 'HotFixCache' into 3.6
This commit is contained in:
5
lib/classes/cache/databox.class.php
vendored
5
lib/classes/cache/databox.class.php
vendored
@@ -112,6 +112,11 @@ class cache_databox
|
|||||||
$field->delete_data_from_cache();
|
$field->delete_data_from_cache();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
foreach($record->get_subdefs() as $subdef)
|
||||||
|
{
|
||||||
|
$subdef->delete_data_from_cache();
|
||||||
|
}
|
||||||
|
|
||||||
break;
|
break;
|
||||||
case 'structure':
|
case 'structure':
|
||||||
$appbox->delete_data_from_cache(\appbox::CACHE_LIST_BASES);
|
$appbox->delete_data_from_cache(\appbox::CACHE_LIST_BASES);
|
||||||
|
@@ -548,10 +548,8 @@ class set_export extends set_abstract
|
|||||||
'path' => $sd[$name]->get_path()
|
'path' => $sd[$name]->get_path()
|
||||||
, 'file' => $sd[$name]->get_file()
|
, 'file' => $sd[$name]->get_file()
|
||||||
);
|
);
|
||||||
if (!$user->ACL()->has_right_on_base(
|
if (!$user->ACL()->has_right_on_base($download_element->get_base_id(), "nowatermark")
|
||||||
$download_element->get_base_id()
|
&& !$user->ACL()->has_preview_grant($download_element)
|
||||||
, "nowatermark"
|
|
||||||
)
|
|
||||||
&& $sd[$name]->get_type() == media_subdef::TYPE_IMAGE)
|
&& $sd[$name]->get_type() == media_subdef::TYPE_IMAGE)
|
||||||
{
|
{
|
||||||
$path = recordutils_image::watermark(
|
$path = recordutils_image::watermark(
|
||||||
@@ -977,11 +975,12 @@ class set_export extends set_abstract
|
|||||||
|
|
||||||
if (is_file($file))
|
if (is_file($file))
|
||||||
{
|
{
|
||||||
$testPath = function($file, $registry){
|
$testPath = function($file, $registry)
|
||||||
return strpos($file, $registry->get('GV_RootPath').'tmp/download/') !== false
|
{
|
||||||
|| strpos($file, $registry->get('GV_RootPath').'tmp/lazaret/') !== false
|
return strpos($file, $registry->get('GV_RootPath') . 'tmp/download/') !== false
|
||||||
|
|| strpos($file, $registry->get('GV_RootPath') . 'tmp/lazaret/') !== false
|
||||||
|| strpos($file, $registry->get('GV_X_Accel_Redirect')) !== false;
|
|| strpos($file, $registry->get('GV_X_Accel_Redirect')) !== false;
|
||||||
};
|
};
|
||||||
|
|
||||||
if ($registry->get('GV_modxsendfile') && $testPath($file, $registry))
|
if ($registry->get('GV_modxsendfile') && $testPath($file, $registry))
|
||||||
{
|
{
|
||||||
|
Reference in New Issue
Block a user