gocodebox / lifterlms

LifterLMS, a WordPress LMS Solution: Easily create, sell, and protect engaging online courses.
https://lifterlms.com
GNU General Public License v3.0
179 stars 134 forks source link

Avoid outputting invalid values in Number input #2658

Closed brianhogg closed 4 months ago

brianhogg commented 4 months ago

Description

When a course is cloned, the default value for an absint field on the course is 0. However this is below the minimum value for the Enable Lesson Drip course-level settings, which blocks save. Instead, when a Number meta box field is rendered, output nothing or empty string if the value is below the minimum for the field.

Fixes #2649

How has this been tested?

Manually

Checklist: