Skip to content

Conversation

@frankmayer
Copy link
Contributor

@frankmayer frankmayer commented Oct 3, 2016

  • com_mailto
  • com_newsfeeds
  • com_search

Note: This is a single commit bundling all types of changes, since PR #12261 which had detailed commits, was rejected as a whole

- com_mailto
- com_newsfeeds
- com_search

Note: This is a single commit bundling all types of changes, since PR #12261 which had detailed commits, was rejected as a whole

// Build the message to send
$msg = JText::_('COM_MAILTO_EMAIL_MSG');
$link = $link;
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nice one! 😉

$levels = $user->getAuthorisedViewLevels();

if (!in_array($item->access, $levels) or ((in_array($item->access, $levels) and (!in_array($item->category_access, $levels)))))
if (!in_array($item->access, $levels) or in_array($item->access, $levels) and (!in_array($item->category_access, $levels)))
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

why not replace the and and or here?

Copy link
Contributor Author

@frankmayer frankmayer Oct 3, 2016

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Slipped through...

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

also maybe you need to add one parenthisis here. not sure tough

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes, precedence maybe.. I mostly picked low hanging fruit.. That's possibly why this one "slipped through" 😄

@andrepereiradasilva
Copy link
Contributor

I have tested this item ✅ successfully on c34e7bf

on code review


This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/12293.

# Conflicts:
#	components/com_newsfeeds/helpers/route.php
#	components/com_newsfeeds/router.php
#	components/com_newsfeeds/views/categories/tmpl/default_items.php
#	components/com_newsfeeds/views/category/tmpl/default_items.php
#	components/com_newsfeeds/views/newsfeed/tmpl/default.php
@frankmayer frankmayer closed this Dec 13, 2016
@frankmayer frankmayer reopened this Dec 13, 2016
@andrepereiradasilva
Copy link
Contributor

I have tested this item ✅ successfully on 2b4d825

code review


This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/12293.

# Conflicts:
#	components/com_newsfeeds/helpers/route.php
#	components/com_newsfeeds/views/newsfeed/tmpl/default.php
#	components/com_newsfeeds/views/newsfeed/view.html.php
@frankmayer
Copy link
Contributor Author

Fixed some conflicts that had occurred in the meantime.
Having merged the changes of above referenced PR's made this PR lighter and easier to test.
It is essentially ready to be merged, when the team finds the time and PR is OK.

$user = JFactory::getUser();

if ($user->get('id') || ($this->input->getMethod() == 'POST' && $vName == 'category' ))
if ($user->get('id') || ($this->input->getMethod() === 'POST' && $vName === 'category' ))
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Remove extra space 'category' )).

// Check for published state if filter set.

if (((is_numeric($published)) || (is_numeric($archived))) && (($data->published != $published) && ($data->published != $archived)))
if ((is_numeric($published) || is_numeric($archived)) && (($data->published != $published) && ($data->published != $archived)))
Copy link
Contributor

@Quy Quy May 28, 2017

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Change (($data->published != $published) && ($data->published != $archived)) to $data->published != $published && $data->published != $archived.


// Are we dealing with a newsfeed that is attached to a menu item?
if (isset($query['view']) && ($mView == $query['view']) and (isset($query['id'])) and ($mId == (int) $query['id']))
if (isset($query['view'], $query['id']) && ($mView == $query['view']) && ($mId == (int) $query['id']))
Copy link
Contributor

@Quy Quy May 28, 2017

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Change && ($mView == $query['view']) && ($mId == (int) $query['id']) to && $mView == $query['view'] && $mId == (int) $query['id'].


<form action="<?php echo htmlspecialchars(JUri::getInstance()->toString(), ENT_COMPAT, 'UTF-8'); ?>" method="post" name="adminForm" id="adminForm">
<?php if ((($this->params->get('filter_field') != 'hide') || ($this->params->get('filter_field') != '0')) || $this->params->get('show_pagination_limit')) :?>
<?php if ((($this->params->get('filter_field') !== 'hide') || ($this->params->get('filter_field') != '0')) || $this->params->get('show_pagination_limit')) :?>
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Remove parentheses.

<?php if ((($this->params->get('filter_field') !== 'hide') || ($this->params->get('filter_field') != '0')) || $this->params->get('show_pagination_limit')) :?>
<fieldset class="filters btn-toolbar">
<?php if (($this->params->get('filter_field') != 'hide') || ($this->params->get('filter_field') != '0')) :?>
<?php if (($this->params->get('filter_field') !== 'hide') || ($this->params->get('filter_field') != '0')) :?>
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Remove parentheses

$direction = ' ';

if ($lang->isRtl() && $myrtl == 0)
$isRtl= $lang->isRtl();
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Align =

# Conflicts:
#	components/com_newsfeeds/views/category/tmpl/default_items.php
#	components/com_search/controller.php
#	components/com_search/views/search/view.html.php
@Quy
Copy link
Contributor

Quy commented May 28, 2017

I have tested this item ✅ successfully on 6cc4c65
Code review


This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/12293.

Copy link
Contributor

@andrepereiradasilva andrepereiradasilva left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

one question with strict compare a integer type with mixed(?) type. please check
the rest seems fine

else
{
if ($child->id == (int) $segment)
if ($child->id === (int) $segment)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Not sure. Will check. According to the property's docblock it is an integer, but I am not sure if we can trust that. See: https://github.com/joomla/joomla-cms/blob/staging/libraries/legacy/categories/categories.php#L395

@andrepereiradasilva
Copy link
Contributor

I have tested this item ✅ successfully on 5b88330


This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/12293.

@frankmayer
Copy link
Contributor Author

@franz-wohlkoenig RTC please , thank you

@joomla-cms-bot joomla-cms-bot added the RTC This Pull Request is Ready To Commit label Jun 2, 2017
@ghost
Copy link

ghost commented Jun 2, 2017

RTC after two successful tests.

@rdeutz rdeutz added this to the Joomla 3.7.3 milestone Jun 8, 2017
@rdeutz rdeutz merged commit 778153e into joomla:staging Jun 8, 2017
@joomla-cms-bot joomla-cms-bot removed the RTC This Pull Request is Ready To Commit label Jun 8, 2017
@frankmayer frankmayer deleted the site-com_mailto-com_newsfeeds-com_search branch June 8, 2017 10:14
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants