Fix adding an item to an empty channel (fixes #104)
This commit is contained in:
parent
fa0e14f729
commit
d7f06ac4fb
1 changed files with 1 additions and 3 deletions
|
@ -53,9 +53,7 @@ function Channel({ id, data }: { id: number; data: PlanItem[] }) {
|
||||||
ref={provided.innerRef}
|
ref={provided.innerRef}
|
||||||
{...provided.droppableProps}
|
{...provided.droppableProps}
|
||||||
>
|
>
|
||||||
{typeof data[id] === "undefined"
|
{data
|
||||||
? null
|
|
||||||
: data
|
|
||||||
.filter((x) => x.channel === id)
|
.filter((x) => x.channel === id)
|
||||||
.sort((a, b) => a.weight - b.weight)
|
.sort((a, b) => a.weight - b.weight)
|
||||||
.map((x, index) => (
|
.map((x, index) => (
|
||||||
|
|
Loading…
Reference in a new issue