Skip to content
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

Get error when running the check command (not usable without the laravel-lang package?) #45

Open
dietergeerts opened this issue Mar 7, 2023 · 0 comments

Comments

@dietergeerts
Copy link

dietergeerts commented Mar 7, 2023

  • LaravelLang Version: 9.1.0
  • Laravel Version: 9.0.0
  • PHP Version: 8.1.0

Description:

I followed the instructions, and when I run the check command, I get the following error

Version 9.1.0 - Created by ARCANEDEV

Checking the missing translations...


   Error 

  Call to a member function mergeTranslations() on null
    151▕
    152▕         $translations = is_null($appLocale)
  ➜ 153▕             ? $vendorLocale->mergeTranslations($appLocale, $ignored)
    154▕             : $appLocale->mergeTranslations($vendorLocale, $ignored);
    155▕
    156▕         return array_filter($translations, function ($key) {
    157▕             return ! Str::startsWith($key, ['validation-inline.']);

      +15 vendor frames
  16  artisan:35
      Illuminate\Foundation\Console\Kernel::handle(Object(Symfony\Component\Console\Input\ArgvInput), Object(Symfony\Component\Console\Output\ConsoleOutput))

Steps To Reproduce:

I followed the instructions like stated, with the following config:

<?php

return [

    /* -----------------------------------------------------------------
     |  The vendor path
     | -----------------------------------------------------------------
     */

    /** @link      https://github.com/Laravel-Lang/lang */
    'vendor' => [
//        base_path('vendor/laravel-lang/lang/locales'),
    ],

    /* -----------------------------------------------------------------
     |  Supported locales
     | -----------------------------------------------------------------
     | If you want to limit your translations, set your supported locales list.
     */

    'locales' => [
        'dev',
        'en',
        'sv',
    ],

    /* -----------------------------------------------------------------
     |  Check Settings
     | -----------------------------------------------------------------
     */

    'check' => [
        'ignore' => [
            'validation.custom',
            'validation.attributes',
        ],
    ],

];
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant