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

Lightswitch in Matrix field deletes all matrix blocks upon save when enabled, deletes blocks site-wide with an enabled lightswitch #4951

Closed
lenchantin opened this issue Sep 17, 2019 · 5 comments

Comments

@lenchantin
Copy link

Description

In my content blocks matrix filed, I have a lightswitch at the end of my biographies block which, in the code, adds an optional HR at the bottom of the block on the page. When you enable the lightswitch to use the feature, it deletes all content blocks from the matrix on that page, and on any other blocks with a lightswitch -- ACROSS THE ENTIRE SITE. There is no error. They just pull a houdini and vanish.

Steps to reproduce

  1. Create a matrix field type.
  2. Create a block that has a lightswitch and any other content.
  3. Attempt to make an entry, and enable the lightswitch field.
  4. Save and Continue Editing.
  5. The block you just created is gone, as are all blocks across the site with a lightswitch in the matrix field.

Additional info

  • Craft version: 3.3.4
  • PHP version: 7.3.7
  • Database driver & version: MySQL 8.0.16
  • Plugins & versions:
    Amazon SES | 1.2.0
    Calendar Links | 1.0.1
    Contact Form | 2.2.5
    Craft Color Mixer | 1.0.7
    DigitalOcean Spaces Volume | 1.1.2
    Feed Me | 4.1.2
    Field Manager | 2.1.0
    Fingerprint Assets | 1.0.1
    Imager | v2.2.0
    Linkit | 1.1.11
    Navigate | 2.4.3
    Range Slider Field for Sprout Forms | 1.0.6
    reCAPTCHA | 1.3.0
    Redactor | 2.4.0
    Redactor Custom Styles | 3.0.2
    Redactor Font Awesome | 2.1.1
    Smart Map | 3.2.2.1
    Smith | 1.0.0
    Sprout Fields | 3.4.4
    Sprout SEO | 4.2.2
    Store Hours | 2.1.1.1
    Super Table | 2.3.0
    Video Embedder | 1.1.4
@panosdigital
Copy link

The exact same thing just happened to one of our sites. Several hundred entries with matrix block and a Lightswitch appear to be missing after the update to v.3.3.4! Can you please help?

@gjhead
Copy link

gjhead commented Sep 17, 2019

Interesting - I just had some issues with a few items too - and they were lightswitch fields. Just completely disappeared when I upgraded to 3.3.4. A rollback to 3.3.3 fixed the issue for me.

@panosdigital
Copy link

In our case downgrading to v.3.3.3 did fix the issue as well. In v.3.3.4 any entries with a Lightswitch regardless of whether they were in matrix blocks, would completely disappear. Thankfully it seems to be a query error.

@brandonkelly
Copy link
Member

We just released Craft 3.3.4.1 with a fix for this. Sorry for the inconvenience!

@narration-sd
Copy link
Contributor

Well done, Brandon - you know I think you guys do terrific support...this time during travel

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

5 participants