array_key_exists() expects parameter 2 to be array, null given
mirazzaq opened this issue · comments
I am getting the following error while creating object, I can not trace why this error is generating.
{
if (function_exists('config_path') &&
file_exists(config_path('pushnotification.php')) &&
function_exists('app')
) {
$configuration = app('config')->get('pushnotification');
} else {
$configuration = include(__DIR__ . '/Config/config.php');
}
if (!array_key_exists($service, $configuration)) {
throw new PushNotificationException("Service '$service' missed in config/pushnotification.php");
}
return $configuration[$service];
}
/**
* Initialize the feedback array
* @return array
*/
protected function initializeFeedback()
{
"array_key_exists() expects parameter 2 to be array, null given"
Hi @mirazzaq ,
Did you run the following command:
php artisan vendor:publish --provider="Edujugon\PushNotification\Providers\PushNotificationServiceProvider" --tag="config"
The issue happen when I run this command.
Though I have library files from another of my project and is now working properly.
So you sorted out the problem, right?
Should we just close this issue then?
Yes please close it.
Please tell how to resolve this issue ?