Skip to content

Commit

Permalink
Merge branch '4.4-dev' into ux-com-users-list-view
Browse files Browse the repository at this point in the history
  • Loading branch information
MacJoom committed Dec 12, 2023
2 parents 6f88656 + 6a177cb commit de76ebf
Show file tree
Hide file tree
Showing 4 changed files with 12 additions and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -100,7 +100,7 @@
<?php endif; ?>
</td>
<td class="d-none d-md-table-cell">
<?php echo htmlspecialchars($item->editor); ?>
<?php echo empty($item->editor) ? $item->editor_user_id : htmlspecialchars($item->editor); ?>
</td>
<td class="text-end">
<?php echo number_format((int) $item->character_count, 0, Text::_('DECIMALS_SEPARATOR'), Text::_('THOUSANDS_SEPARATOR')); ?>
Expand Down
8 changes: 6 additions & 2 deletions build/media_source/com_finder/js/finder.es6.js
Original file line number Diff line number Diff line change
Expand Up @@ -22,15 +22,19 @@
try {
response = JSON.parse(xhr.responseText);
} catch (e) {
Joomla.renderMessages(Joomla.ajaxErrorsMessages(xhr, 'parsererror'));
// Something went wrong, but we are not going to bother the enduser with this
// eslint-disable-next-line no-console
console.error(e);
return;
}

if (Object.prototype.toString.call(response.suggestions) === '[object Array]') {
target.awesomplete.list = response.suggestions;
}
}).catch((xhr) => {
Joomla.renderMessages(Joomla.ajaxErrorsMessages(xhr));
// Something went wrong, but we are not going to bother the enduser with this
// eslint-disable-next-line no-console
console.error(xhr);
});
}
};
Expand Down
2 changes: 1 addition & 1 deletion components/com_contact/src/Model/ContactModel.php
Original file line number Diff line number Diff line change
Expand Up @@ -104,7 +104,7 @@ protected function populateState()
*/
public function getForm($data = [], $loadData = true)
{
$form = $this->loadForm('com_contact.contact', 'contact', ['control' => 'jform', 'load_data' => true]);
$form = $this->loadForm('com_contact.contact', 'contact', ['control' => 'jform', 'load_data' => $loadData]);

if (empty($form)) {
return false;
Expand Down
6 changes: 4 additions & 2 deletions libraries/src/Installer/InstallerScript.php
Original file line number Diff line number Diff line change
Expand Up @@ -141,7 +141,7 @@ public function preflight($type, $parent)

// Abort if the extension being installed is not newer than the currently installed version
if (!$this->allowDowngrades && strtolower($type) === 'update') {
$manifest = $this->getItemArray('manifest_cache', '#__extensions', 'element', $this->extension);
$manifest = $this->getItemArray('manifest_cache', '#__extensions', 'name', $this->extension);

// Check whether we have an old release installed and skip this check when this here is the initial install.
if (!isset($manifest['version'])) {
Expand Down Expand Up @@ -301,7 +301,9 @@ public function getItemArray($element, $table, $column, $identifier)
$db->setQuery($query);

// Load the single cell and json_decode data
return json_decode($db->loadResult(), true);
$result = $db->loadResult();

return $result === null ? [] : json_decode($result, true);
}

/**
Expand Down

0 comments on commit de76ebf

Please sign in to comment.