~emersion/drmdb

1c4c2c9dad972fca3ef386bea4750ca224913d58 — Simon Ser 19 days ago 6c71d49
Fix percentage with format/modifier filter
1 files changed, 4 insertions(+), 5 deletions(-)

M server.go
M server.go => server.go +4 -5
@@ 615,11 615,6 @@ func New() *echo.Echo {
					continue
				}

				if _, ok := planeFormats[plane.Type()]; !ok {
					planeFormats[plane.Type()] = make(map[modifierAndFormat]bool)
					planes[plane.Type()]++
				}

				inFormats := plane.InFormats()
				for _, mod := range inFormats {
					if modifierFilter != drm.ModifierINVALID && mod.Modifier != modifierFilter {


@@ 641,6 636,10 @@ func New() *echo.Echo {
							}
						}

						if _, ok := planeFormats[plane.Type()]; !ok {
							planes[plane.Type()]++
							planeFormats[plane.Type()] = make(map[modifierAndFormat]bool)
						}
						if !planeFormats[plane.Type()][k] {
							formats[k].Planes[plane.Type()]++
							planeFormats[plane.Type()][k] = true