Skip to content

Commit

Permalink
Merge upstream/staging into remove-trailing-slash-in-url
Browse files Browse the repository at this point in the history
  • Loading branch information
RolandSM committed May 15, 2020
2 parents 6911f81 + 24d0372 commit 84e986d
Show file tree
Hide file tree
Showing 24 changed files with 105 additions and 74 deletions.
2 changes: 1 addition & 1 deletion .appveyor.yml
Original file line number Diff line number Diff line change
Expand Up @@ -127,7 +127,7 @@ install:
- IF %PHP%==1 echo opcache.enable_cli=1 >> php.ini
- IF %PHP%==1 echo extension=php_ldap.dll >> php.ini
- IF %PHP%==1 echo @php %%~dp0composer.phar %%* > composer.bat
- appveyor-retry appveyor DownloadFile https://getcomposer.org/composer.phar
- IF %PHP%==1 php -r "readfile('http://getcomposer.org/installer');" | php
- cd C:\projects\joomla-cms
- appveyor-retry composer install --no-progress --profile

Expand Down
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
DROP INDEX "#__users_username";
DROP INDEX IF EXISTS "#__users_username";
ALTER TABLE "#__users" ADD CONSTRAINT "#__users_idx_username" UNIQUE ("username");
Original file line number Diff line number Diff line change
Expand Up @@ -129,6 +129,7 @@ public function execute()
break;

case 'save':
$this->app->enqueueMessage(JText::_('COM_CONFIG_SAVE_SUCCESS'), 'message');
default:
$redirect = 'index.php?option=' . $option;

Expand Down
2 changes: 1 addition & 1 deletion administrator/components/com_messages/models/message.php
Original file line number Diff line number Diff line change
Expand Up @@ -334,7 +334,7 @@ public function save($data)
return false;
}

if ($config->get('locked', false))
if ($config->get('lock', false))
{
$this->setError(JText::_('COM_MESSAGES_ERR_SEND_FAILED'));

Expand Down
11 changes: 7 additions & 4 deletions administrator/components/com_postinstall/controllers/message.php
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,9 @@ class PostinstallControllerMessage extends FOFController
*/
public function reset()
{
// CSRF prevention.
$this->_csrfProtection();

/** @var PostinstallModelMessages $model */
$model = $this->getThisModel();

Expand All @@ -49,6 +52,9 @@ public function reset()
*/
public function hideAll()
{
// CSRF prevention.
$this->_csrfProtection();

/** @var PostinstallModelMessages $model */
$model = $this->getThisModel();

Expand All @@ -74,10 +80,7 @@ public function hideAll()
public function action()
{
// CSRF prevention.
if ($this->csrfProtection)
{
$this->_csrfProtection();
}
$this->_csrfProtection();

$model = $this->getThisModel();

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,7 @@
<form action="index.php" method="post" name="adminForm" class="form-inline" id="adminForm">
<input type="hidden" name="option" value="com_postinstall">
<input type="hidden" name="task" value="">
<?php echo JHtml::_('form.token'); ?>
<label for="eid"><?php echo JText::_('COM_POSTINSTALL_MESSAGES_FOR'); ?></label>
<?php echo JHtml::_('select.genericlist', $this->extension_options, 'eid', array('onchange' => 'this.form.submit()', 'class' => 'input-xlarge'), 'value', 'text', $this->eid, 'eid'); ?>
</form>
Expand Down
1 change: 1 addition & 0 deletions administrator/language/en-GB/en-GB.com_admin.ini
Original file line number Diff line number Diff line change
Expand Up @@ -139,6 +139,7 @@ COM_ADMIN_PLATFORM_VERSION="Joomla! Platform Version"
COM_ADMIN_REGISTER_GLOBALS="Register Globals"
COM_ADMIN_RELEVANT_PHP_SETTINGS="Relevant PHP Settings"
COM_ADMIN_SAFE_MODE="Safe Mode"
COM_ADMIN_SAVE_SUCCESS="Profile saved."
COM_ADMIN_SEARCH="Search"
COM_ADMIN_SESSION_AUTO_START="Session Auto Start"
COM_ADMIN_SESSION_SAVE_PATH="Session Save Path"
Expand Down
2 changes: 2 additions & 0 deletions administrator/language/en-GB/en-GB.com_messages.ini
Original file line number Diff line number Diff line change
Expand Up @@ -67,6 +67,7 @@ COM_MESSAGES_PLEASE_LOGIN="Please log in to %s to read your message."
COM_MESSAGES_RE="Re:"
COM_MESSAGES_READ="Messages"
COM_MESSAGES_READ_PRIVATE_MESSAGE="Read Private Message"
COM_MESSAGES_SAVE_SUCCESS="Message sent."
COM_MESSAGES_SEARCH_IN_SUBJECT="Search in message subject and description."
COM_MESSAGES_TOOLBAR_MARK_AS_READ="Mark as Read"
COM_MESSAGES_TOOLBAR_MARK_AS_UNREAD="Mark as Unread"
Expand All @@ -76,5 +77,6 @@ COM_MESSAGES_TOOLBAR_SEND="Send"
COM_MESSAGES_VIEW_PRIVATE_MESSAGE="Private Messages: View"
COM_MESSAGES_WRITE_PRIVATE_MESSAGE="Private Messages: Write"
COM_MESSAGES_XML_DESCRIPTION="Component for private messaging support in Backend."
; The following string is deprecated and will be removed with 4.0.
JLIB_APPLICATION_SAVE_SUCCESS="Message sent."
JLIB_RULES_SETTING_NOTES="Changes apply to this component only.<br /><em><strong>Inherited</strong></em> - a Global Configuration setting or higher level setting is applied.<br /><em><strong>Denied</strong></em> always wins - whatever is set at the Global or higher level and applies to all child elements.<br /><em><strong>Allowed</strong></em> will enable the action for this component unless overruled by a Global Configuration setting."
4 changes: 2 additions & 2 deletions administrator/language/en-GB/en-GB.localise.php
Original file line number Diff line number Diff line change
Expand Up @@ -32,11 +32,11 @@ public static function getPluralSuffixes($count)
}
elseif ($count == 1)
{
return array('1');
return array('ONE', '1');
}
else
{
return array('MORE');
return array('OTHER', 'MORE');
}
}

Expand Down
20 changes: 5 additions & 15 deletions components/com_config/view/modules/tmpl/default_options.php
Original file line number Diff line number Diff line change
Expand Up @@ -30,21 +30,11 @@
<?php foreach ($this->form->getFieldset($name) as $field) : ?>

<li>
<div class="control-group">
<div class="control-label">
<?php echo $field->label; ?>
</div>
<div class="controls">
<?php
// If multi-language site, make menu-type selection read-only
if (JLanguageMultilang::isEnabled() && $this->item['module'] === 'mod_menu' && $field->getAttribute('name') === 'menutype')
{
$field->__set('readonly', true);
}
echo $field->input;
?>
</div>
</div>
<?php // If multi-language site, make menu-type selection read-only ?>
<?php if (JLanguageMultilang::isEnabled() && $this->item['module'] === 'mod_menu' && $field->getAttribute('name') === 'menutype') : ?>
<?php $field->readonly = true; ?>
<?php endif; ?>
<?php echo $field->renderField(); ?>
</li>

<?php endforeach; ?>
Expand Down
2 changes: 1 addition & 1 deletion components/com_contact/views/featured/tmpl/default.xml
Original file line number Diff line number Diff line change
Expand Up @@ -454,7 +454,7 @@
<field
name="linkb_name"
type="text"
label="COM_CONTACT_FIELD_LINKB_LABEL"
label="COM_CONTACT_FIELD_LINKB_NAME_LABEL"
description="COM_CONTACT_FIELD_LINK_NAME_DESC"
size="30"
useglobal="true"
Expand Down
2 changes: 1 addition & 1 deletion components/com_users/controllers/registration.php
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,7 @@ public function activate()
if (($uParams->get('useractivation') == 2) && $userToActivate->getParam('activate', 0))
{
// If a user admin is not logged in, redirect them to the login page with an error message
if (!$user->authorise('core.create', 'com_users'))
if (!$user->authorise('core.create', 'com_users') || !$user->authorise('core.manage', 'com_users'))
{
$activationUrl = 'index.php?option=com_users&task=registration.activate&token=' . $token;
$loginUrl = 'index.php?option=com_users&view=login&return=' . base64_encode($activationUrl);
Expand Down
2 changes: 1 addition & 1 deletion components/com_users/models/registration.php
Original file line number Diff line number Diff line change
Expand Up @@ -170,7 +170,7 @@ public function activate($token)
{
$usercreator = JFactory::getUser($row->id);

if ($usercreator->authorise('core.create', 'com_users'))
if ($usercreator->authorise('core.create', 'com_users') && $usercreator->authorise('core.manage', 'com_users'))
{
$return = JFactory::getMailer()->sendMail($data['mailfrom'], $data['fromname'], $row->email, $emailSubject, $emailBody);

Expand Down

0 comments on commit 84e986d

Please sign in to comment.