- Fix include path
- Add hack protection - check for smarty cache path
This commit is contained in:
parent
d154d41ee3
commit
75578dbf0c
|
@ -1,5 +1,9 @@
|
||||||
<?php
|
<?php
|
||||||
|
|
||||||
|
if (IN_serendipity !== true) {
|
||||||
|
die ("Don't hack!");
|
||||||
|
}
|
||||||
|
|
||||||
@serendipity_plugin_api::load_language(dirname(__FILE__));
|
@serendipity_plugin_api::load_language(dirname(__FILE__));
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
@ -238,6 +242,9 @@ class serendipity_event_lsrstopper extends serendipity_event
|
||||||
protected function getCacheFilename($url)
|
protected function getCacheFilename($url)
|
||||||
{
|
{
|
||||||
global $serendipity;
|
global $serendipity;
|
||||||
|
if (!defined('PATH_SMARTY_COMPILE')) {
|
||||||
|
return '';
|
||||||
|
}
|
||||||
return $serendipity['serendipityPath'] . '/' . PATH_SMARTY_COMPILE . '/lsrstopper/' . md5($url);
|
return $serendipity['serendipityPath'] . '/' . PATH_SMARTY_COMPILE . '/lsrstopper/' . md5($url);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -1,7 +1,7 @@
|
||||||
<?php
|
<?php
|
||||||
|
|
||||||
require_once S9Y_INCLUDE_PATH . 'tests/plugins/PluginTest.php';
|
require_once S9Y_INCLUDE_PATH . 'tests/plugins/PluginTest.php';
|
||||||
require_once S9Y_INCLUDE_PATH . 'plugins/serendipity_event_lsrstopper/serendipity_event_lsrstopper.php';
|
require_once S9Y_INCLUDE_PATH . 'plugins/additional_plugins/serendipity_event_lsrstopper/serendipity_event_lsrstopper.php';
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Class serendipity_event_lsrstopperTest
|
* Class serendipity_event_lsrstopperTest
|
||||||
|
|
Loading…
Reference in a new issue