Skip to content

Commit

Permalink
Removed explicit string casting.
Browse files Browse the repository at this point in the history
  • Loading branch information
Christian Achatz committed May 19, 2018
1 parent 0d96791 commit dccef22
Show file tree
Hide file tree
Showing 4 changed files with 5 additions and 5 deletions.
2 changes: 1 addition & 1 deletion core/errorhandler/controller/ErrorPageController.php
Expand Up @@ -48,7 +48,7 @@ public function transformContent() {
$model = Singleton::getInstance(ErrorPageViewModel::class);

$errors = array_reverse(debug_backtrace());
$buffer = (string)'';
$buffer = '';

$errorEntry = $this->getTemplate('ErrorEntry');

Expand Down
Expand Up @@ -55,7 +55,7 @@ public function transformContent() {
// load the entries using the business component
$entries = $m->loadEntries();

$buffer = (string)'';
$buffer = '';
$template = $this->getTemplate('ArticleComment');

$i = 1;
Expand Down
2 changes: 1 addition & 1 deletion tools/form/taglib/SelectBoxTag.php
Expand Up @@ -349,7 +349,7 @@ public function transform() {

// create html code
if ($this->isVisible) {
$select = (string)'';
$select = '';
$select .= '<select ' . $this->getSanitizedAttributesAsString($this->attributes) . '>';

$this->transformChildren();
Expand Down
4 changes: 2 additions & 2 deletions tools/string/StringAssistant.php
Expand Up @@ -65,7 +65,7 @@ public static function encodeCharactersToHTML(string $string) {

$content = trim($string);

$encodedContent = (string)'';
$encodedContent = '';

for ($i = 0; $i < strlen($content); $i++) {
$encodedContent .= '&#' . ord($content[$i]) . ';';
Expand Down Expand Up @@ -93,7 +93,7 @@ public static function generateCaptchaString(int $length) {

$characterBase = 'ABCDEFGHJKLMNPRSTUVWXYZabcdefghijkmnpqrstuvwxyz23456789';

$string = (string)'';
$string = '';

while (strlen($string) < $length) {
$string .= substr($characterBase, (rand() % (strlen($characterBase))), 1);
Expand Down

0 comments on commit dccef22

Please sign in to comment.