Skip to content

Commit

Permalink
Fix di:compile errors
Browse files Browse the repository at this point in the history
  • Loading branch information
tuyennn committed Sep 14, 2017
1 parent bbfad76 commit 26f97aa
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 18 deletions.
7 changes: 4 additions & 3 deletions Model/Instagram.php
@@ -1,7 +1,7 @@
<?php

namespace GhoSter\AutoInstagramPost\Model;
use GhoSter\AutoInstagramPost\Helper\Data as Helper;



class Instagram
Expand Down Expand Up @@ -37,13 +37,14 @@ class Instagram
* Default folder to store data, you can change it.
*
* @param \Magento\Framework\App\Filesystem\DirectoryList $directory_list
* @param \GhoSter\AutoInstagramPost\Helper\Data $helper
* @param \Psr\Log\LoggerInterface $logger
* @param array $data
*/
public function __construct(
\Magento\Framework\App\Filesystem\DirectoryList $directory_list,
Helper $helper,
LoggerInterface $logger,
\GhoSter\AutoInstagramPost\Helper\Data $helper,
\Psr\Log\LoggerInterface $logger,
array $data = []
)
{
Expand Down
6 changes: 1 addition & 5 deletions Observer/Catalog/ProductSaveAfter.php
Expand Up @@ -3,7 +3,6 @@
namespace GhoSter\AutoInstagramPost\Observer\Catalog;

use Magento\Framework\Event\ObserverInterface;
use Psr\Log\LoggerInterface;
use GhoSter\AutoInstagramPost\Helper\Data as AutoPostHelper;
use GhoSter\AutoInstagramPost\Model\Instagram;

Expand Down Expand Up @@ -41,7 +40,6 @@ class ProductSaveAfter implements ObserverInterface
/**
* ProductSaveAfter constructor.
* @param \Magento\Framework\App\Action\Context $context
* @param \Magento\Framework\ObjectManagerInterface $objectManager
* @param \GhoSter\AutoInstagramPost\Helper\Data $helper
* @param \GhoSter\AutoInstagramPost\Model\Instagram $instagram
* @param \Psr\Log\LoggerInterface $logger
Expand All @@ -51,17 +49,15 @@ class ProductSaveAfter implements ObserverInterface
*/
public function __construct(
\Magento\Framework\App\Action\Context $context,
\Magento\Framework\ObjectManagerInterface $objectManager,
AutoPostHelper $helper,
Instagram $instagram,
LoggerInterface $logger,
\Psr\Log\LoggerInterface $logger,
\Magento\Framework\App\Filesystem\DirectoryList $directory_list,
\Magento\Catalog\Api\ProductRepositoryInterfaceFactory $productRepositoryFactory,
\Magento\Framework\Json\Helper\Data $jsonHelper

)
{
$this->_objectManager = $objectManager;
$this->helper = $helper;
$this->instagram = $instagram;
$this->logger = $logger;
Expand Down
12 changes: 2 additions & 10 deletions Setup/Uninstall.php
@@ -1,15 +1,9 @@
<?php
/**
* Copyright © 2016 MageWorx. All rights reserved.
* See LICENSE.txt for license details.
*/

namespace GhoSter\AutoInstagramPost\Setup;

use Magento\Framework\Setup\UninstallInterface;
use Magento\Framework\Setup\SchemaSetupInterface;
use Magento\Framework\Setup\ModuleContextInterface;
use Magento\Framework\Setup\ModuleDataSetupInterface;
use Magento\Eav\Setup\EavSetup;
use Magento\Eav\Setup\EavSetupFactory;

Expand Down Expand Up @@ -38,13 +32,11 @@ public function __construct(EavSetupFactory $eavSetupFactory)
*
* @param SchemaSetupInterface $setup
* @param ModuleContextInterface $context
* @param ModuleDataSetupInterface $dataSetup
* @return void
*/
public function uninstall(
SchemaSetupInterface $setup,
ModuleContextInterface $context,
ModuleDataSetupInterface $dataSetup
ModuleContextInterface $context
) {
$setup->startSetup();

Expand All @@ -53,7 +45,7 @@ public function uninstall(
$connection->dropTable($connection->getTableName('ghoster_instagram_auto_post'));

/** @var EavSetup $eavSetup */
$eavSetup = $this->eavSetupFactory->create(['setup' => $dataSetup]);
$eavSetup = $this->eavSetupFactory->create();

/**
* Remove attributes to the eav/attribute
Expand Down

0 comments on commit 26f97aa

Please sign in to comment.