Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
AStA
Erstitüte Backend
Commits
ef39a0ed
Commit
ef39a0ed
authored
Apr 01, 2021
by
Leon Tappe
🔥
Browse files
add forgotten if statement for slim mode
parent
35c7c653
Changes
1
Hide whitespace changes
Inline
Side-by-side
lib/controller/vendor_controller.dart
View file @
ef39a0ed
...
...
@@ -91,12 +91,14 @@ class VendorController extends ResourceController {
}
final
vendors
=
await
vendorQuery
.
fetch
();
vendors
.
forEach
((
Vendor
v
)
{
if
(
v
.
properties
?.
data
!=
null
)
{
(
v
.
properties
.
data
as
Map
<
String
,
dynamic
>).
removeWhere
(
(
String
key
,
dynamic
value
)
=>
key
==
'image'
||
key
==
'logo'
||
key
==
'product'
);
}
});
if
(
slim
==
'true'
)
{
vendors
.
forEach
((
Vendor
v
)
{
if
(
v
.
properties
?.
data
!=
null
)
{
(
v
.
properties
.
data
as
Map
<
String
,
dynamic
>).
removeWhere
(
(
String
key
,
dynamic
value
)
=>
key
==
'image'
||
key
==
'logo'
||
key
==
'product'
);
}
});
}
return
Response
.
ok
(
vendors
);
}
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment