Skip to content

Commit 25aaa92

Browse files
committed
Fix assets counting.
1 parent 0685bd4 commit 25aaa92

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

internal/database/mariadb.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -527,7 +527,7 @@ func (m *MariaDB) FlushAll() error {
527527
// CountAssets count the total number of assets in db.
528528
func (m *MariaDB) CountAssets() (int64, error) {
529529
var count int64
530-
row := m.db.QueryRowContext(context.Background(), "SELECT COUNT(*) FROM assets")
530+
row := m.db.QueryRowContext(context.Background(), "SELECT COUNT(DISTINCT value, type) FROM assets")
531531

532532
err := row.Scan(&count)
533533
if err != nil {

0 commit comments

Comments
 (0)