Skip to content

[feature/test-1]: Fixed the PHPCS error and optimize the code #1

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

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 6 additions & 0 deletions Helper/Data.php
Original file line number Diff line number Diff line change
Expand Up @@ -63,6 +63,8 @@ public function getConfig($field, $default="", $store = null)
if($result == "") {
$result = $default;
}

Copy link
Collaborator

Choose a reason for hiding this comment

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

Lorem Ipsum is simply dummy text of the printing and typesetting industry. Lorem Ipsum has been the industry's standard dummy text ever since the 1500s, when an unknown printer took a galley of type and scrambled it to make a type specimen book.


return $result;
}

Expand All @@ -82,6 +84,7 @@ public function getConfigData($field, $store = null)
$field,
\Magento\Store\Model\ScopeInterface::SCOPE_STORE,
$store);

return $result;
}

Expand All @@ -91,6 +94,8 @@ public function getConfigData($field, $store = null)
* @param string $str
* @return string
*/


public function filter($str)
{
Copy link
Collaborator

Choose a reason for hiding this comment

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

It has survived not only five centuries, but also the leap into electronic typesetting, remaining essentially unchanged. It was popularised in the 1960s with the release of Letraset sheets containing Lorem Ipsum passages, and more recently with desktop publishing software like Aldus PageMaker including versions of Lorem Ipsum.

$html = $this->_filterProvider->getPageFilter()->filter($str);
Expand All @@ -105,6 +110,7 @@ public function filter($str)
*/
public function isEnabled($storeId = null)
{

return $this->getConfigData(self::XML_PATH_GENERAL_ENABLED, $storeId);
}

Expand Down
4 changes: 4 additions & 0 deletions Model/Config/Source/Categories.php
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,8 @@

namespace Tutorialstab\LazyloadingInfiniteScroll\Model\Config\Source;



/**
* Categories
* @package Tutorialstab_ImportExportCategories
Expand All @@ -16,6 +18,8 @@ class Categories implements \Magento\Framework\Option\ArrayInterface {
* @var \Magento\User\Model\UserFactory
*/
protected $_categoryFactory;



/**
* @param \Magento\Catalog\Model\CategoryFactory $categoryFactory
Expand Down