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

No validation on Channel Default Guest Author #37

Closed
obfuscode opened this Issue Dec 2, 2018 · 1 comment

Comments

Projects
None yet
2 participants
@obfuscode
Copy link

obfuscode commented Dec 2, 2018

Description of the problem
If a channel's default guest author is deleted from the system, trying to save the channel settings results in a DB error on MySQL 5.7+

How To Reproduce
Steps to reproduce the behavior:

  1. Create channel with default guest author set
  2. Delete default guest author member account
  3. Edit / save channel settings

Error Messages


SQLSTATE[23000]: Integrity constraint violation: 1048 Column 'default_author' cannot be null:
UPDATE `exp_channel_form_settings` SET `default_author` = NULL WHERE `channel_form_settings_id` = 3

Environment Details:

  • Version: 5.0.1
  • PHP Version 7.2
  • MySQL Version 5.7
  • OS: macOS
  • Web Server: nginx

Possible Solution
Add validation check on default_author field.

Additional context
Admittedly, this is an edge case.

@kevincupp

This comment has been minimized.

Copy link
Contributor

kevincupp commented Dec 6, 2018

Closed via b7a9974, put wrong issue number in the commit. Thanks, @obfuscode!

@kevincupp kevincupp closed this Dec 6, 2018

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment