feat: links all cursor pagination

This commit is contained in:
sjdonado
2025-03-16 18:30:52 +01:00
parent 1967cc2c22
commit cd6dfa345b
2 changed files with 27 additions and 4 deletions
+4 -1
View File
@@ -16,7 +16,10 @@ module App::Serializers
builder.field("id", @link.id)
builder.field("refer", @refer)
builder.field("origin", @link.url)
builder.field("clicks", @link.clicks.map { |click| App::Serializers::Click.new(click) })
unless @link.clicks.empty?
builder.field("clicks", @link.clicks.map { |click| App::Serializers::Click.new(click) })
end
end
end
end