Merge pull request #6349 from open-sausages/pulls/4.0/fix-cms-crash

Temp patch to 5987 to prevent cms crashing
This commit is contained in:
Daniel Hensby 2016-11-30 10:02:13 +00:00 committed by GitHub
commit d9537eb76b
2 changed files with 6 additions and 0 deletions

View File

@ -689,12 +689,15 @@ class ShortcodeParser extends Object
}
$location = self::INLINE;
/**
* Below code disabled due to https://github.com/silverstripe/silverstripe-framework/issues/5987
if ($class == 'left' || $class == 'right') {
$location = self::BEFORE;
}
if ($class == 'center' || $class == 'leftAlone') {
$location = self::SPLIT;
}
*/
if (!$parent) {
if ($location !== self::INLINE) {

View File

@ -188,6 +188,9 @@ class ShortcodeParserTest extends SapphireTest {
}
public function testtExtract() {
$this->markTestSkipped(
'Feature disabled due to https://github.com/silverstripe/silverstripe-framework/issues/5987'
);
// Left extracts to before the current block
$this->assertEqualsIgnoringWhitespace(
'Code<div>FooBar</div>',