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

Add type hint to prevent error #214

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open

Conversation

kaptk2
Copy link

@kaptk2 kaptk2 commented Jun 19, 2024

Fixes #213

@joelclermont
Copy link

This did not fix the issue for me. I traced the ErrorException to the presence of nesbot/carbon:^3.0 instead of nesbot/carbon:^2.0. Once I downgraded, the error went away.

If it helps, here's more info:

With carbon 2 installed, the $diff object near where the error is thrown is

DateInterval {#3796
  interval: - 1m 4d
  +"y": 0
  +"m": 1
  +"d": 4
  +"h": 0
  +"i": 0
  +"s": 0
  +"f": 0.0
  +"invert": 1
  +"days": 35
  +"from_string": false
}

With Carbon 3 installed, it's

Carbon\CarbonInterval�]8;;file:https:///app/vendor/nesbot/carbon/src/Carbon/CarbonInterval.php#L194�\^�]8;;�\ {#4244
  interval: - 1m 4d
  #timezoneSetting: null
  #originalInput: DateInterval {#3868
    interval: - 1m 4d
    +"y": 0
    +"m": 1
    +"d": 4
    +"h": 0
    +"i": 0
    +"s": 0
    +"f": 0.0
    +"invert": 1
    +"days": 35
    +"from_string": false
  }
  #startDate: Illuminate\Support\Carbon @1580950800�]8;;file:https:///app/vendor/laravel/framework/src/Illuminate/Support/Carbon.php#L12�\^�]8;;�\ {#3999
    #endOfTime: false
    #startOfTime: false
    #constructedObjectId: "0000000000000f9f0000000000000000"
    -clock: null
    #localMonthsOverflow: null
    #localYearsOverflow: null
    #localStrictModeEnabled: null
    #localHumanDiffOptions: null
    #localToStringFormat: null
    #localSerializer: null
    #localMacros: null
    #localGenericMacros: null
    #localFormatFunction: null
    #localTranslator: null
    #dumpProperties: array:3 [
      0 => "date"
      1 => "timezone_type"
      2 => "timezone"
    ]
    #dumpLocale: null
    #dumpDateProperties: null
    date: 2020-02-05 19:00:00.0 America/Chicago (-06:00)
  }
  #endDate: Illuminate\Support\Carbon @1577926800�]8;;file:https:///app/vendor/laravel/framework/src/Illuminate/Support/Carbon.php#L12�\^�]8;;�\ {#4247
    #endOfTime: false
    #startOfTime: false
    #constructedObjectId: "00000000000010970000000000000000"
    -clock: null
    #localMonthsOverflow: null
    #localYearsOverflow: null
    #localStrictModeEnabled: null
    #localHumanDiffOptions: null
    #localToStringFormat: null
    #localSerializer: null
    #localMacros: null
    #localGenericMacros: null
    #localFormatFunction: null
    #localTranslator: null
    #dumpProperties: array:3 [
      0 => "date"
      1 => "timezone_type"
      2 => "timezone"
    ]
    #dumpLocale: null
    #dumpDateProperties: null
    date: 2020-01-01 19:00:00.0 America/Chicago (-06:00)
  }
  #rawInterval: DateInterval {#3868}
  #initialValues: array:9 [
    0 => 0
    1 => 1
    2 => 4
    3 => 0
    4 => 0
    5 => 0
    6 => 0.0
    7 => 1
    8 => false
  ]
  -clock: null
  #step: null
  #localMonthsOverflow: null
  #localYearsOverflow: null
  #localStrictModeEnabled: null
  #localHumanDiffOptions: null
  #localToStringFormat: null
  #localSerializer: null
  #localMacros: null
  #localGenericMacros: null
  #localFormatFunction: null
  #localTranslator: Carbon\Translator�]8;;file:https:///app/vendor/nesbot/carbon/src/Carbon/Translator.php#L31�\^�]8;;�\ {#1589
    #catalogues: array:1 [
      "en" => Symfony\Component\Translation\MessageCatalogue�]8;;file:https:///app/vendor/symfony/translation/MessageCatalogue.php#L20�\^�]8;;�\ {#3786
        -messages: array:1 [
          "messages" => array:97 [
            "year" => "{1}:count year|{0}:count years|]1,Inf[:count years"
            "a_year" => "{1}a year|{0}:count years|]1,Inf[:count years"
            "y" => "{1}:countyr|{0}:countyrs|]1,Inf[:countyrs"
            "month" => "{1}:count month|{0}:count months|]1,Inf[:count months"
            "a_month" => "{1}a month|{0}:count months|]1,Inf[:count months"
            "m" => "{1}:countmo|{0}:countmos|]1,Inf[:countmos"
            "week" => "{1}:count week|{0}:count weeks|]1,Inf[:count weeks"
            "a_week" => "{1}a week|{0}:count weeks|]1,Inf[:count weeks"
            "w" => ":countw"
            "day" => "{1}:count day|{0}:count days|]1,Inf[:count days"
            "a_day" => "{1}a day|{0}:count days|]1,Inf[:count days"
            "d" => ":countd"
            "hour" => "{1}:count hour|{0}:count hours|]1,Inf[:count hours"
            "a_hour" => "{1}an hour|{0}:count hours|]1,Inf[:count hours"
            "h" => ":counth"
            "minute" => "{1}:count minute|{0}:count minutes|]1,Inf[:count minutes"
            "a_minute" => "{1}a minute|{0}:count minutes|]1,Inf[:count minutes"
            "min" => ":countm"
            "second" => "{1}:count second|{0}:count seconds|]1,Inf[:count seconds"
            "a_second" => "{1}a few seconds|{0}:count seconds|]1,Inf[:count seconds"
            "s" => ":counts"
            "millisecond" => "{1}:count millisecond|{0}:count milliseconds|]1,Inf[:count milliseconds"
            "a_millisecond" => "{1}a millisecond|{0}:count milliseconds|]1,Inf[:count milliseconds"
            "ms" => ":countms"
            "microsecond" => "{1}:count microsecond|{0}:count microseconds|]1,Inf[:count microseconds"
            "a_microsecond" => "{1}a microsecond|{0}:count microseconds|]1,Inf[:count microseconds"
            "µs" => ":countµs"
            "ago" => ":time ago"
            "from_now" => ":time from now"
            "after" => ":time after"
            "before" => ":time before"
            "diff_now" => "just now"
            "diff_today" => "today"
            "diff_yesterday" => "yesterday"
            "diff_tomorrow" => "tomorrow"
            "diff_before_yesterday" => "before yesterday"
            "diff_after_tomorrow" => "after tomorrow"
            "period_recurrences" => "{1}once|{0}:count times|]1,Inf[:count times"
            "period_interval" => "every :interval"
            "period_start_date" => "from :date"
            "period_end_date" => "to :date"
            "months.0" => "January"
            "months.1" => "February"
            "months.2" => "March"
            "months.3" => "April"
            "months.4" => "May"
            "months.5" => "June"
            "months.6" => "July"
            "months.7" => "August"
            "months.8" => "September"
            "months.9" => "October"
            "months.10" => "November"
            "months.11" => "December"
            "months_short.0" => "Jan"
            "months_short.1" => "Feb"
            "months_short.2" => "Mar"
            "months_short.3" => "Apr"
            "months_short.4" => "May"
            "months_short.5" => "Jun"
            "months_short.6" => "Jul"
            "months_short.7" => "Aug"
            "months_short.8" => "Sep"
            "months_short.9" => "Oct"
            "months_short.10" => "Nov"
            "months_short.11" => "Dec"
            "weekdays.0" => "Sunday"
            "weekdays.1" => "Monday"
            "weekdays.2" => "Tuesday"
            "weekdays.3" => "Wednesday"
            "weekdays.4" => "Thursday"
            "weekdays.5" => "Friday"
            "weekdays.6" => "Saturday"
            "weekdays_short.0" => "Sun"
            "weekdays_short.1" => "Mon"
            "weekdays_short.2" => "Tue"
            "weekdays_short.3" => "Wed"
            "weekdays_short.4" => "Thu"
            "weekdays_short.5" => "Fri"
            "weekdays_short.6" => "Sat"
            "weekdays_min.0" => "Su"
            "weekdays_min.1" => "Mo"
            "weekdays_min.2" => "Tu"
            "weekdays_min.3" => "We"
            "weekdays_min.4" => "Th"
            "weekdays_min.5" => "Fr"
            "weekdays_min.6" => "Sa"
            "ordinal" => Closure($number)�]8;;file:https:///app/vendor/nesbot/carbon/src/Carbon/Lang/en.php#L71�\^�]8;;�\ {#1597
              class: "�]8;;file:https:///app/vendor/nesbot/carbon/src/Carbon/Translator.php#L31�\Carbon\Translator�]8;;�\"
            }
            "formats.LT" => "h:mm A"
            "formats.LTS" => "h:mm:ss A"
            "formats.L" => "MM/DD/YYYY"
            "formats.LL" => "MMMM D, YYYY"
            "formats.LLL" => "MMMM D, YYYY h:mm A"
            "formats.LLLL" => "dddd, MMMM D, YYYY h:mm A"
            "list.0" => ", "
            "list.1" => " and "
            "first_day_of_week" => 1
            "day_of_first_week_of_year" => 1
          ]
        ]
        -metadata: []
        -catalogueMetadata: []
        -resources: []
        -locale: "en"
        -fallbackCatalogue: null
        -parent: null
      }
    ]
    -locale: "en"
    -fallbackLocales: []
    -loaders: array:1 [
      "array" => Symfony\Component\Translation\Loader\ArrayLoader�]8;;file:https:///app/vendor/symfony/translation/Loader/ArrayLoader.php#L21�\^�]8;;�\ {#1588}
    ]
    -resources: array:1 [
      "en" => array:1 [
        0 => array:3 [
          0 => "array"
          1 => array:51 [
            "year" => "{1}:count year|{0}:count years|]1,Inf[:count years"
            "a_year" => "{1}a year|{0}:count years|]1,Inf[:count years"
            "y" => "{1}:countyr|{0}:countyrs|]1,Inf[:countyrs"
            "month" => "{1}:count month|{0}:count months|]1,Inf[:count months"
            "a_month" => "{1}a month|{0}:count months|]1,Inf[:count months"
            "m" => "{1}:countmo|{0}:countmos|]1,Inf[:countmos"
            "week" => "{1}:count week|{0}:count weeks|]1,Inf[:count weeks"
            "a_week" => "{1}a week|{0}:count weeks|]1,Inf[:count weeks"
            "w" => ":countw"
            "day" => "{1}:count day|{0}:count days|]1,Inf[:count days"
            "a_day" => "{1}a day|{0}:count days|]1,Inf[:count days"
            "d" => ":countd"
            "hour" => "{1}:count hour|{0}:count hours|]1,Inf[:count hours"
            "a_hour" => "{1}an hour|{0}:count hours|]1,Inf[:count hours"
            "h" => ":counth"
            "minute" => "{1}:count minute|{0}:count minutes|]1,Inf[:count minutes"
            "a_minute" => "{1}a minute|{0}:count minutes|]1,Inf[:count minutes"
            "min" => ":countm"
            "second" => "{1}:count second|{0}:count seconds|]1,Inf[:count seconds"
            "a_second" => "{1}a few seconds|{0}:count seconds|]1,Inf[:count seconds"
            "s" => ":counts"
            "millisecond" => "{1}:count millisecond|{0}:count milliseconds|]1,Inf[:count milliseconds"
            "a_millisecond" => "{1}a millisecond|{0}:count milliseconds|]1,Inf[:count milliseconds"
            "ms" => ":countms"
            "microsecond" => "{1}:count microsecond|{0}:count microseconds|]1,Inf[:count microseconds"
            "a_microsecond" => "{1}a microsecond|{0}:count microseconds|]1,Inf[:count microseconds"
            "µs" => ":countµs"
            "ago" => ":time ago"
            "from_now" => ":time from now"
            "after" => ":time after"
            "before" => ":time before"
            "diff_now" => "just now"
            "diff_today" => "today"
            "diff_yesterday" => "yesterday"
            "diff_tomorrow" => "tomorrow"
            "diff_before_yesterday" => "before yesterday"
            "diff_after_tomorrow" => "after tomorrow"
            "period_recurrences" => "{1}once|{0}:count times|]1,Inf[:count times"
            "period_interval" => "every :interval"
            "period_start_date" => "from :date"
            "period_end_date" => "to :date"
            "months" => array:12 [
              0 => "January"
              1 => "February"
              2 => "March"
              3 => "April"
              4 => "May"
              5 => "June"
              6 => "July"
              7 => "August"
              8 => "September"
              9 => "October"
              10 => "November"
              11 => "December"
            ]
            "months_short" => array:12 [
              0 => "Jan"
              1 => "Feb"
              2 => "Mar"
              3 => "Apr"
              4 => "May"
              5 => "Jun"
              6 => "Jul"
              7 => "Aug"
              8 => "Sep"
              9 => "Oct"
              10 => "Nov"
              11 => "Dec"
            ]
            "weekdays" => array:7 [
              0 => "Sunday"
              1 => "Monday"
              2 => "Tuesday"
              3 => "Wednesday"
              4 => "Thursday"
              5 => "Friday"
              6 => "Saturday"
            ]
            "weekdays_short" => array:7 [
              0 => "Sun"
              1 => "Mon"
              2 => "Tue"
              3 => "Wed"
              4 => "Thu"
              5 => "Fri"
              6 => "Sat"
            ]
            "weekdays_min" => array:7 [
              0 => "Su"
              1 => "Mo"
              2 => "Tu"
              3 => "We"
              4 => "Th"
              5 => "Fr"
              6 => "Sa"
            ]
            "ordinal" => Closure($number)�]8;;file:https:///app/vendor/nesbot/carbon/src/Carbon/Lang/en.php#L71�\^�]8;;�\ {#1597}
            "formats" => array:6 [
              "LT" => "h:mm A"
              "LTS" => "h:mm:ss A"
              "L" => "MM/DD/YYYY"
              "LL" => "MMMM D, YYYY"
              "LLL" => "MMMM D, YYYY h:mm A"
              "LLLL" => "dddd, MMMM D, YYYY h:mm A"
            ]
            "list" => array:2 [
              0 => ", "
              1 => " and "
            ]
            "first_day_of_week" => 1
            "day_of_first_week_of_year" => 1
          ]
          2 => "messages"
        ]
      ]
    ]
    -formatter: Carbon\MessageFormatter\MessageFormatterMapper�]8;;file:https:///app/vendor/nesbot/carbon/src/Carbon/MessageFormatter/MessageFormatterMapper.php#L28�\^�]8;;�\ {#1587
      #formatter: Symfony\Component\Translation\Formatter\MessageFormatter�]8;;file:https:///app/vendor/symfony/translation/Formatter/MessageFormatter.php#L23�\^�]8;;�\ {#1594
        -translator: Symfony\Component\Translation\IdentityTranslator�]8;;file:https:///app/vendor/symfony/translation/IdentityTranslator.php#L23�\^�]8;;�\ {#1596
          -locale: null
        }
        -intlFormatter: Symfony\Component\Translation\Formatter\IntlFormatter�]8;;file:https:///app/vendor/symfony/translation/Formatter/IntlFormatter.php#L21�\^�]8;;�\ {#1595
          -hasMessageFormatter: ? bool
          -cache: []
        }
      }
    }
    -cacheDir: null
    -debug: false
    -cacheVary: []
    -configCacheFactory: ? ?Symfony\Component\Config\ConfigCacheFactoryInterface
    -parentLocales: array:140 [
      "az_Cyrl" => "root"
      "bs_Cyrl" => "root"
      "en_150" => "en_001"
      "en_AG" => "en_001"
      "en_AI" => "en_001"
      "en_AT" => "en_150"
      "en_AU" => "en_001"
      "en_BB" => "en_001"
      "en_BE" => "en_150"
      "en_BM" => "en_001"
      "en_BS" => "en_001"
      "en_BW" => "en_001"
      "en_BZ" => "en_001"
      "en_CC" => "en_001"
      "en_CH" => "en_150"
      "en_CK" => "en_001"
      "en_CM" => "en_001"
      "en_CX" => "en_001"
      "en_CY" => "en_001"
      "en_DE" => "en_150"
      "en_DG" => "en_001"
      "en_DK" => "en_150"
      "en_DM" => "en_001"
      "en_ER" => "en_001"
      "en_FI" => "en_150"
      "en_FJ" => "en_001"
      "en_FK" => "en_001"
      "en_FM" => "en_001"
      "en_GB" => "en_001"
      "en_GD" => "en_001"
      "en_GG" => "en_001"
      "en_GH" => "en_001"
      "en_GI" => "en_001"
      "en_GM" => "en_001"
      "en_GY" => "en_001"
      "en_HK" => "en_001"
      "en_ID" => "en_001"
      "en_IE" => "en_001"
      "en_IL" => "en_001"
      "en_IM" => "en_001"
      "en_IN" => "en_001"
      "en_IO" => "en_001"
      "en_JE" => "en_001"
      "en_JM" => "en_001"
      "en_KE" => "en_001"
      "en_KI" => "en_001"
      "en_KN" => "en_001"
      "en_KY" => "en_001"
      "en_LC" => "en_001"
      "en_LR" => "en_001"
      "en_LS" => "en_001"
      "en_MG" => "en_001"
      "en_MO" => "en_001"
      "en_MS" => "en_001"
      "en_MT" => "en_001"
      "en_MU" => "en_001"
      "en_MV" => "en_001"
      "en_MW" => "en_001"
      "en_MY" => "en_001"
      "en_NA" => "en_001"
      "en_NF" => "en_001"
      "en_NG" => "en_001"
      "en_NL" => "en_150"
      "en_NR" => "en_001"
      "en_NU" => "en_001"
      "en_NZ" => "en_001"
      "en_PG" => "en_001"
      "en_PK" => "en_001"
      "en_PN" => "en_001"
      "en_PW" => "en_001"
      "en_RW" => "en_001"
      "en_SB" => "en_001"
      "en_SC" => "en_001"
      "en_SD" => "en_001"
      "en_SE" => "en_150"
      "en_SG" => "en_001"
      "en_SH" => "en_001"
      "en_SI" => "en_150"
      "en_SL" => "en_001"
      "en_SS" => "en_001"
      "en_SX" => "en_001"
      "en_SZ" => "en_001"
      "en_TC" => "en_001"
      "en_TK" => "en_001"
      "en_TO" => "en_001"
      "en_TT" => "en_001"
      "en_TV" => "en_001"
      "en_TZ" => "en_001"
      "en_UG" => "en_001"
      "en_VC" => "en_001"
      "en_VG" => "en_001"
      "en_VU" => "en_001"
      "en_WS" => "en_001"
      "en_ZA" => "en_001"
      "en_ZM" => "en_001"
      "en_ZW" => "en_001"
      "es_AR" => "es_419"
      "es_BO" => "es_419"
      "es_BR" => "es_419"
      "es_BZ" => "es_419"
      "es_CL" => "es_419"
      "es_CO" => "es_419"
      "es_CR" => "es_419"
      "es_CU" => "es_419"
      "es_DO" => "es_419"
      "es_EC" => "es_419"
      "es_GT" => "es_419"
      "es_HN" => "es_419"
      "es_MX" => "es_419"
      "es_NI" => "es_419"
      "es_PA" => "es_419"
      "es_PE" => "es_419"
      "es_PR" => "es_419"
      "es_PY" => "es_419"
      "es_SV" => "es_419"
      "es_US" => "es_419"
      "es_UY" => "es_419"
      "es_VE" => "es_419"
      "ff_Adlm" => "root"
      "hi_Latn" => "en_IN"
      "ks_Deva" => "root"
      "nb" => "no"
      "nn" => "no"
      "pa_Arab" => "root"
      "pt_AO" => "pt_PT"
      "pt_CH" => "pt_PT"
      "pt_CV" => "pt_PT"
      "pt_GQ" => "pt_PT"
      "pt_GW" => "pt_PT"
      "pt_LU" => "pt_PT"
      "pt_MO" => "pt_PT"
      "pt_MZ" => "pt_PT"
      "pt_ST" => "pt_PT"
      "pt_TL" => "pt_PT"
      "sd_Deva" => "root"
      "sr_Latn" => "root"
      "uz_Arab" => "root"
      "uz_Cyrl" => "root"
      "zh_Hant" => "root"
      "zh_Hant_MO" => "zh_Hant_HK"
    ]
    -hasIntlFormatter: false
    #messages: array:1 [
      "en" => array:51 [
        "year" => "{1}:count year|{0}:count years|]1,Inf[:count years"
        "a_year" => "{1}a year|{0}:count years|]1,Inf[:count years"
        "y" => "{1}:countyr|{0}:countyrs|]1,Inf[:countyrs"
        "month" => "{1}:count month|{0}:count months|]1,Inf[:count months"
        "a_month" => "{1}a month|{0}:count months|]1,Inf[:count months"
        "m" => "{1}:countmo|{0}:countmos|]1,Inf[:countmos"
        "week" => "{1}:count week|{0}:count weeks|]1,Inf[:count weeks"
        "a_week" => "{1}a week|{0}:count weeks|]1,Inf[:count weeks"
        "w" => ":countw"
        "day" => "{1}:count day|{0}:count days|]1,Inf[:count days"
        "a_day" => "{1}a day|{0}:count days|]1,Inf[:count days"
        "d" => ":countd"
        "hour" => "{1}:count hour|{0}:count hours|]1,Inf[:count hours"
        "a_hour" => "{1}an hour|{0}:count hours|]1,Inf[:count hours"
        "h" => ":counth"
        "minute" => "{1}:count minute|{0}:count minutes|]1,Inf[:count minutes"
        "a_minute" => "{1}a minute|{0}:count minutes|]1,Inf[:count minutes"
        "min" => ":countm"
        "second" => "{1}:count second|{0}:count seconds|]1,Inf[:count seconds"
        "a_second" => "{1}a few seconds|{0}:count seconds|]1,Inf[:count seconds"
        "s" => ":counts"
        "millisecond" => "{1}:count millisecond|{0}:count milliseconds|]1,Inf[:count milliseconds"
        "a_millisecond" => "{1}a millisecond|{0}:count milliseconds|]1,Inf[:count milliseconds"
        "ms" => ":countms"
        "microsecond" => "{1}:count microsecond|{0}:count microseconds|]1,Inf[:count microseconds"
        "a_microsecond" => "{1}a microsecond|{0}:count microseconds|]1,Inf[:count microseconds"
        "µs" => ":countµs"
        "ago" => ":time ago"
        "from_now" => ":time from now"
        "after" => ":time after"
        "before" => ":time before"
        "diff_now" => "just now"
        "diff_today" => "today"
        "diff_yesterday" => "yesterday"
        "diff_tomorrow" => "tomorrow"
        "diff_before_yesterday" => "before yesterday"
        "diff_after_tomorrow" => "after tomorrow"
        "period_recurrences" => "{1}once|{0}:count times|]1,Inf[:count times"
        "period_interval" => "every :interval"
        "period_start_date" => "from :date"
        "period_end_date" => "to :date"
        "months" => array:12 [
          0 => "January"
          1 => "February"
          2 => "March"
          3 => "April"
          4 => "May"
          5 => "June"
          6 => "July"
          7 => "August"
          8 => "September"
          9 => "October"
          10 => "November"
          11 => "December"
        ]
        "months_short" => array:12 [
          0 => "Jan"
          1 => "Feb"
          2 => "Mar"
          3 => "Apr"
          4 => "May"
          5 => "Jun"
          6 => "Jul"
          7 => "Aug"
          8 => "Sep"
          9 => "Oct"
          10 => "Nov"
          11 => "Dec"
        ]
        "weekdays" => array:7 [
          0 => "Sunday"
          1 => "Monday"
          2 => "Tuesday"
          3 => "Wednesday"
          4 => "Thursday"
          5 => "Friday"
          6 => "Saturday"
        ]
        "weekdays_short" => array:7 [
          0 => "Sun"
          1 => "Mon"
          2 => "Tue"
          3 => "Wed"
          4 => "Thu"
          5 => "Fri"
          6 => "Sat"
        ]
        "weekdays_min" => array:7 [
          0 => "Su"
          1 => "Mo"
          2 => "Tu"
          3 => "We"
          4 => "Th"
          5 => "Fr"
          6 => "Sa"
        ]
        "ordinal" => Closure($number)�]8;;file:https:///app/vendor/nesbot/carbon/src/Carbon/Lang/en.php#L71�\^�]8;;�\ {#1597}
        "formats" => array:6 [
          "LT" => "h:mm A"
          "LTS" => "h:mm:ss A"
          "L" => "MM/DD/YYYY"
          "LL" => "MMMM D, YYYY"
          "LLL" => "MMMM D, YYYY h:mm A"
          "LLLL" => "dddd, MMMM D, YYYY h:mm A"
        ]
        "list" => array:2 [
          0 => ", "
          1 => " and "
        ]
        "first_day_of_week" => 1
        "day_of_first_week_of_year" => 1
      ]
    ]
    #directories: array:1 [
      0 => "/app/vendor/nesbot/carbon/src/Carbon/Lang"
    ]
    #initializing: false
    #aliases: array:2 [
      "me" => "sr_Latn_ME"
      "scr" => "sh"
    ]
    locale: "en"
  }
  +"y": 0
  +"m": 1
  +"d": 4
  +"h": 0
  +"i": 0
  +"s": 0
  +"f": 0.0
  +"invert": 1
  +"days": false
  +"from_string": false
  startDate: Illuminate\Support\Carbon @1580950800�]8;;file:https:///app/vendor/laravel/framework/src/Illuminate/Support/Carbon.php#L12�\^�]8;;�\ {#3999}
  endDate: Illuminate\Support\Carbon @1577926800�]8;;file:https:///app/vendor/laravel/framework/src/Illuminate/Support/Carbon.php#L12�\^�]8;;�\ {#4247}
  rawInterval: DateInterval {#3868}
  initialValues: array:9 [
    0 => 0
    1 => 1
    2 => 4
    3 => 0
    4 => 0
    5 => 0
    6 => 0.0
    7 => 1
    8 => false
  ]
  localTranslator: Carbon\Translator�]8;;file:https:///app/vendor/nesbot/carbon/src/Carbon/Translator.php#L31�\^�]8;;�\ {#1589}
}

Not only is it a different kind of object, but the latter version has days property set to false. Hope this helps! For now, I downgraded Carbon and I'm back in business.

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

Successfully merging this pull request may close these issues.

Increment on type bool has no effect, this will change in the next major version of PHP
2 participants