From c1463b36ef7199d0f31286200808835b8c0d12c5 Mon Sep 17 00:00:00 2001 From: Lucas Gabriel Vuotto Date: Sat, 3 May 2025 17:55:26 +0000 Subject: [PATCH] api/v0: make Tags model random_id return the display --- lib/Pooru/API/V0/Model/Tags.pm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/Pooru/API/V0/Model/Tags.pm b/lib/Pooru/API/V0/Model/Tags.pm index 73e7ec9..c02b19c 100644 --- a/lib/Pooru/API/V0/Model/Tags.pm +++ b/lib/Pooru/API/V0/Model/Tags.pm @@ -23,7 +23,7 @@ sub count ($self) sub random_id ($self) { my $row = $self->{_dbh}->selectrow_arrayref(q{ - SELECT id FROM tag ORDER BY random() LIMIT 1 + SELECT display FROM tag ORDER BY random() LIMIT 1 }); return defined($row) ? $row->[0] : undef;