Skip to content

[6.x] Bard: Adding a Bard set fails with "Something went wrong" #13665

@o1y

Description

@o1y

Bug description

When adding a set in Bard this fails with a really generic toast "Something went wrong" - nothing is logged in the console.

The response from the server returned 200.

The actual JS error seems to be swallowed by the catch block, which made debugging difficult. After temporarily modifying the catch to log the error this reveals:

ReferenceError: index is not defined at addSet (BardFieldtype.vue:495)

When you try to add a Bard set in a replicator you'll get

Uncaught TypeError: can't access property "[set_handle]", this.meta.defaults is undefined

How to reproduce

Add a Set in Bard

Logs

Environment

v6.0.0-beta.5

Installation

Fresh statamic/statamic site via CLI

Additional details

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions