Skip to content

Commit

Permalink
Merge pull request #69 from YotpoLtd/v1.4.6
Browse files Browse the repository at this point in the history
v1.4.6: Fixed deprecation issue on CLI - Symfony: Command::execute() should always return int...
  • Loading branch information
pniel-cohen authored Dec 20, 2023
2 parents dcd04c9 + 71bbda9 commit ab14427
Show file tree
Hide file tree
Showing 5 changed files with 17 additions and 10 deletions.
6 changes: 4 additions & 2 deletions Console/Command/RemoveOldSyncRecordsCommand.php
Original file line number Diff line number Diff line change
Expand Up @@ -14,11 +14,10 @@
*/
class RemoveOldSyncRecordsCommand extends Command
{

/**#@+
* Keys and shortcuts for input arguments and options
*/
const FORCE = 'force';
public const FORCE = 'force';
/**#@- */

/**
Expand Down Expand Up @@ -83,6 +82,9 @@ protected function execute(InputInterface $input, OutputInterface $output)
$output->writeln('<info>' . 'Done :)' . '</info>');
} catch (\Exception $e) {
$output->writeln('<error>' . $e->getMessage() . '</error>');
return 1;
}

return 0;
}
}
8 changes: 5 additions & 3 deletions Console/Command/SyncCommand.php
Original file line number Diff line number Diff line change
Expand Up @@ -13,12 +13,11 @@
*/
class SyncCommand extends Command
{

/**#@+
* Keys and shortcuts for input arguments and options
*/
const FORCE = 'force';
const LIMIT = 'limit';
public const FORCE = 'force';
public const LIMIT = 'limit';
/**#@- */

/**
Expand Down Expand Up @@ -90,6 +89,9 @@ protected function execute(InputInterface $input, OutputInterface $output)
$output->writeln('<info>' . 'Done :)' . '</info>');
} catch (\Exception $e) {
$output->writeln('<error>' . $e->getMessage() . '</error>');
return 1;
}

return 0;
}
}
9 changes: 6 additions & 3 deletions Console/Command/UninstallCommand.php
Original file line number Diff line number Diff line change
Expand Up @@ -12,10 +12,10 @@

class UninstallCommand extends Command
{
const CONFIRM_MESSAGE = "<question>Are you sure you want to uninstall Yotpo? (y/n)[n]\n*This will remove all Yotpo attributes & data from DB.\n*This process is irreversible! You should backup first.</question>\n";
const RESET_CONFIG_CONFIRM_MESSAGE = "<question>Do you want to also remove all Yotpo configurations (reset to default)? (y/n)[n]</question>\n";
public const CONFIRM_MESSAGE = "<question>Are you sure you want to uninstall Yotpo? (y/n)[n]\n*This will remove all Yotpo attributes & data from DB.\n*This process is irreversible! You should backup first.</question>\n";
public const RESET_CONFIG_CONFIRM_MESSAGE = "<question>Do you want to also remove all Yotpo configurations (reset to default)? (y/n)[n]</question>\n";

const SQL_QUERIES = [
public const SQL_QUERIES = [
"default" => [
"DELETE FROM `setup_module` WHERE `setup_module`.`module` = 'Yotpo_Loyalty'",
],
Expand Down Expand Up @@ -116,7 +116,10 @@ protected function execute(InputInterface $input, OutputInterface $output)
$output->writeln('<info>' . 'Done :(' . '</info>');
} catch (\Exception $e) {
$output->writeln('<error>' . $e->getMessage() . '</error>');
return 1;
}

return 0;
}

/**
Expand Down
2 changes: 1 addition & 1 deletion composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
"name": "yotpo/magento2-module-yotpo-loyalty",
"description": "Magento 2 module for integration with Yotpo",
"type": "magento2-module",
"version": "1.4.5",
"version": "1.4.6",
"repositories": [{
"type": "git",
"url": "https://github.com/YotpoLtd/magento2-module-yotpo-loyalty"
Expand Down
2 changes: 1 addition & 1 deletion etc/module.xml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?xml version="1.0"?>
<config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="urn:magento:framework:Module/etc/module.xsd">
<module name="Yotpo_Loyalty" setup_version="1.4.5">
<module name="Yotpo_Loyalty" setup_version="1.4.6">
<sequence>
<module name="Magento_Catalog" />
</sequence>
Expand Down

0 comments on commit ab14427

Please sign in to comment.