Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Updated sprintf usage; Simplified isset usage #21096

Merged
merged 2 commits into from
Feb 13, 2019

Conversation

df2k2
Copy link
Contributor

@df2k2 df2k2 commented Feb 9, 2019

Description (*)

1. Simplified if condition using AND-logic (&&) for checking two isset statements to use a single one with multiple parameters. By definition isset():

If multiple parameters are supplied then isset() will return TRUE only if all of the parameters are set. Evaluation goes from left to right and stops as soon as an unset variable is encountered.
https://secure.php.net/manual/en/function.isset.php

2. Updated sprintf() usage:

i. Removed unnecessary sprintf() where no parameters are specified.
ii. Removed unused parameters from sprintf() usage.

Contribution checklist (*)

  • Pull request has a meaningful description of its purpose
  • All commits are accompanied by meaningful commit messages
  • All new or changed code is covered with unit/integration tests (if applicable)
  • All automated tests passed successfully (all builds on Travis CI are green)

@magento-engcom-team
Copy link
Contributor

Hi @df2k2. Thank you for your contribution
Here is some useful tips how you can test your changes using Magento test environment.
Add the comment under your pull request to deploy test or vanilla Magento instance:

  • @magento-engcom-team give me test instance - deploy test instance based on PR changes
  • @magento-engcom-team give me 2.3-develop instance - deploy vanilla Magento instance

For more details, please, review the Magento Contributor Assistant documentation

@magento-engcom-team
Copy link
Contributor

Hi @sidolov, thank you for the review.
ENGCOM-4191 has been created to process this Pull Request

@magento-engcom-team magento-engcom-team merged commit 9ad428d into magento:2.3-develop Feb 13, 2019
@ghost
Copy link

ghost commented Feb 13, 2019

Hi @df2k2, thank you for your contribution!
Please, complete Contribution Survey, it will take less than a minute.
Your feedback will help us to improve contribution process.

@df2k2 df2k2 deleted the 2.3-dev-sprintf-1 branch February 13, 2019 22:16
@sidolov sidolov added this to the Release: 2.3.2 milestone Feb 13, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants