From 766ce65d0bc864e8cf87aac51c7271e144dc0103 Mon Sep 17 00:00:00 2001 From: Andrew O'Neil Date: Wed, 22 Oct 2008 03:48:20 +0000 Subject: [PATCH] MINOR: PHP notice fixes git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/branches/2.2@64638 467b73ca-7a2a-4603-9d3b-597d59a354a9 --- core/model/DataObjectSet.php | 2 +- core/model/fieldtypes/Text.php | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/core/model/DataObjectSet.php b/core/model/DataObjectSet.php index 08f568416..402a238e0 100644 --- a/core/model/DataObjectSet.php +++ b/core/model/DataObjectSet.php @@ -573,7 +573,7 @@ class DataObjectSet extends ViewableData implements IteratorAggregate { * @return array */ public function map($key = "ID", $value = "Title", $includeBlank=null) { - + $map = array(); /* Don't do this, add this locally. * Reasons: 1: In some case this blank value don't/mustn't present. 2: In some case, this balnk value should be customised, such as (Select from below) diff --git a/core/model/fieldtypes/Text.php b/core/model/fieldtypes/Text.php index f4c1135f9..eb9e72d2a 100644 --- a/core/model/fieldtypes/Text.php +++ b/core/model/fieldtypes/Text.php @@ -73,6 +73,7 @@ class Text extends DBField { * @param int $sentCount The amount of sentences you want. */ function LimitSentences($sentCount = 2) { + $output = ''; $data = Convert::xml2raw($this->value); $sentences = explode('.', $data); if(count($sentences) == 1) {