Skip to content

Instance:FindFirstChild() and Instance:FindFirstAncestor() can't always be compared with nil #76

@ghost

Description

--!strict
local model = Instance.new("Model")
assert(model:FindFirstChild("does_not_exist") ~= nil) -- This warns.
assert(workspace:FindFirstChild("does_not_exist") ~= nil) -- This is fine.
TypeError: Types Instance and nil cannot be compared with ~= because they do not have the same metatable

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions