mirror of
https://github.com/penpot/penpot.git
synced 2025-01-23 23:18:48 -05:00
Fix icons sql functions.
This commit is contained in:
parent
e1ff8aa11e
commit
4aa888f72d
1 changed files with 4 additions and 2 deletions
|
@ -15,7 +15,8 @@ returning *;
|
|||
select *,
|
||||
(select count(*) from icons where collection = ic.id) as num_icons
|
||||
from icons_collections as ic
|
||||
where ic."user" = :user
|
||||
where (ic."user" = :user or
|
||||
ic."user" = '00000000-0000-0000-0000-000000000000'::uuid)
|
||||
and ic.deleted_at is null
|
||||
order by ic.created_at desc;
|
||||
|
||||
|
@ -27,7 +28,8 @@ update icons_collections
|
|||
-- :name get-icons-by-collection :? :*
|
||||
select *
|
||||
from icons as i
|
||||
where i."user" = :user
|
||||
where (i."user" = :user or
|
||||
i."user" = '00000000-0000-0000-0000-000000000000'::uuid)
|
||||
and i.deleted_at is null
|
||||
and i."collection" = :collection
|
||||
order by i.created_at desc;
|
||||
|
|
Loading…
Add table
Reference in a new issue