Skip to content

Commit

Permalink
Minor changes & codestyle
Browse files Browse the repository at this point in the history
  • Loading branch information
frankmayer committed Dec 31, 2016
1 parent dde3a96 commit 4d24de3
Showing 1 changed file with 10 additions and 11 deletions.
21 changes: 10 additions & 11 deletions libraries/cms/installer/installer.php
Original file line number Diff line number Diff line change
Expand Up @@ -2252,20 +2252,19 @@ public static function parseXMLInstallFile($path)
// Check if we're a language. If so use metafile.
$data['type'] = $xml->getName() == 'metafile' ? 'language' : (string) $xml->attributes()->type;

$data['creationDate'] = ((string) $xml->creationDate) ? (string) $xml->creationDate : JText::_('JLIB_UNKNOWN');
$data['author'] = ((string) $xml->author) ? (string) $xml->author : JText::_('JLIB_UNKNOWN');

$data['copyright'] = (string) $xml->copyright;
$data['authorEmail'] = (string) $xml->authorEmail;
$data['authorUrl'] = (string) $xml->authorUrl?: $xml->authorURL;
$data['authorURL'] = &$data['authorUrl'];
$data['version'] = (string) $xml->version;
$data['description'] = (string) $xml->description;
$data['group'] = (string) $xml->group;
$data['creationDate'] = (string) $xml->creationDate ?: JText::_('JLIB_UNKNOWN');
$data['author'] = (string) $xml->author ?: JText::_('JLIB_UNKNOWN');
$data['copyright'] = (string) $xml->copyright;
$data['authorEmail'] = (string) $xml->authorEmail;
$data['authorUrl'] = (string) $xml->authorUrl ?: (string) $xml->authorURL;
$data['authorURL'] = &$data['authorUrl'];
$data['version'] = (string) $xml->version;
$data['description'] = (string) $xml->description;
$data['group'] = (string) $xml->group;

if ($xml->files && count($xml->files->children()))
{
$filename = JFile::getName($path);
$filename = JFile::getName($path);
$data['filename'] = JFile::stripExt($filename);

foreach ($xml->files->children() as $oneFile)
Expand Down

0 comments on commit 4d24de3

Please sign in to comment.