# fluent-cart/1.6.4/app/Events/StockChanged.php

FluentCart A New Era of eCommerce – Faster, Lighter, and Simpler, version 1.6.4. 48 lines.

- Page: https://pluginprobe.com/plugins/fluent-cart/1.6.4/code/app/Events/StockChanged.php
- Raw: https://pluginprobe.com/plugins/fluent-cart/1.6.4/raw/app/Events/StockChanged.php
- Modified: 2026-06-11T12:21:58+00:00

Line numbers below start at 1. Link to a line or a range by appending a fragment to the
page URL, for example `https://pluginprobe.com/plugins/fluent-cart/1.6.4/code/app/Events/StockChanged.php#L10-L20`.

```php
<?php

namespace FluentCart\App\Events;

use FluentCart\App\Listeners\UpdateDefaultVariation;

class StockChanged extends EventDispatcher
{
    public string $hook = 'fluent_cart/product_stock_changed';
    protected array $listeners = [
        //UpdateDefaultVariation::class
    ];

    /**
     * @var array $postIds
     */
    public $postIds;

    /**
     * @var array|null $otherInfo
     */
    public ?array $otherInfo;

    public function __construct($postIds, $otherInfo = null)
    {
        $this->postIds = $postIds;
        $this->otherInfo = $otherInfo;
    }

    public function toArray(): array
    {
        return [
            'post_ids'   => $this->postIds,
            'other_info' => $this->otherInfo,
        ];
    }

    public function getActivityEventModel()
    {
        return null;
    }

    public function shouldCreateActivity(): bool
    {
        return false;
    }

}
```
