string format error when hitting 'expand all' button in pet list, with world event filter active #225


  • Bug
Open
  • EnigmaniteZ created this issue Jan 22, 2021

    What exactly is wrong?

     UI pane errors

    What steps will reproduce the problem?
    1. scan pets.

    2. set filter to world events only

    3. hit expand all button

     

    Any additional information?

    this error is due to a function being passed a nil instead of an expected string.

    /collectinator/utilities.lua@55:
    return ("|cff%s%s|r"):format(color_code or "ffffff", text)

    this should be:

    return ("|cff%s%s|r"):format(color_code or "ffffff", text or "")

     

    If you get an error, please paste the ENTIRE thing here:

    Message: Interface\AddOns\Collectinator\Utilities.lua:55: bad argument #2 to 'format' (string expected, got nil)
    Time: Thu Jan 21 22:43:27 2021
    Count: 6
    Stack: Interface\AddOns\Collectinator\Utilities.lua:55: bad argument #2 to 'format' (string expected, got nil)
    [string "=[C]"]: in function `format'
    [string "@Interface\AddOns\Collectinator\Utilities.lua"]:55: in function <Interface\AddOns\Collectinator\Utilities.lua:54>
    [string "@Interface\AddOns\Collectinator\Interface\List.lua"]:1188: in function `func'
    [string "@Interface\AddOns\Collectinator\Interface\List.lua"]:1379: in function <Interface\AddOns\Collectinator\Interface\List.lua:1328>
    [string "@Interface\AddOns\Collectinator\Interface\List.lua"]:1518: in function `ExpandEntry'
    [string "@Interface\AddOns\Collectinator\Interface\List.lua"]:450: in function `InsertEntry'
    [string "@Interface\AddOns\Collectinator\Interface\Tabs.lua"]:410: in function `Initialize'
    [string "@Interface\AddOns\Collectinator\Interface\List.lua"]:790: in function `Initialize'
    [string "@Interface\AddOns\Collectinator\Interface\List.lua"]:850: in function `Update'
    [string "@Interface\AddOns\Collectinator\Interface\Panel.lua"]:770: in function <Interface\AddOns\Collectinator\Interface\Panel.lua:753>

    Locals: (*temporary) = "|cff%s%s"
    (*temporary) = "80590e"
    (*temporary) = nil
    (*temporary) = "string expected, got nil"

     

  • EnigmaniteZ added a tag Bug Jan 22, 2021

To post a comment, please login or register a new account.