Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
A
admin-fe
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container Registry
Model registry
Operate
Environments
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Pleroma
admin-fe
Commits
8e1825ae
Commit
8e1825ae
authored
4 years ago
by
Angelina Filippova
Browse files
Options
Downloads
Patches
Plain Diff
Fix parsing and wrapping tuple values in Args setting inside Pleroma.Upload.Filter.Mogrify
parent
659adbe6
No related branches found
Branches containing commit
No related tags found
Tags containing commit
1 merge request
!151
Add missing settings
Pipeline
#29355
failed
4 years ago
Stage: build
Stage: test
Changes
2
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
src/store/modules/normalizers.js
+1
-13
1 addition, 13 deletions
src/store/modules/normalizers.js
src/views/settings/components/inputComponents/SpecificMultipleSelect.vue
+5
-3
5 additions, 3 deletions
...ngs/components/inputComponents/SpecificMultipleSelect.vue
with
6 additions
and
16 deletions
src/store/modules/normalizers.js
+
1
−
13
View file @
8e1825ae
...
...
@@ -50,12 +50,7 @@ export const parseNonTuples = (key, value) => {
return
updated
}
if
(
key
===
'
:args
'
)
{
if
(
typeof
value
===
'
string
'
)
{
return
[
value
]
}
const
index
=
value
.
findIndex
(
el
=>
typeof
el
===
'
object
'
&&
el
.
tuple
.
includes
(
'
implode
'
))
const
updated
=
value
.
map
((
el
,
i
)
=>
i
===
index
?
'
implode
'
:
el
)
return
updated
return
typeof
value
===
'
string
'
?
[
value
]
:
value
}
return
value
}
...
...
@@ -259,13 +254,6 @@ const wrapValues = (settings, currentState) => {
}
else
if
(
setting
===
'
:ip
'
)
{
const
ip
=
value
.
split
(
'
.
'
).
map
(
s
=>
parseInt
(
s
,
10
))
return
{
'
tuple
'
:
[
setting
,
{
'
tuple
'
:
ip
}]
}
}
else
if
(
setting
===
'
:args
'
)
{
const
index
=
value
.
findIndex
(
el
=>
el
===
'
implode
'
)
const
updatedArray
=
value
.
slice
()
if
(
index
!==
-
1
)
{
updatedArray
[
index
]
=
{
'
tuple
'
:
[
'
implode
'
,
'
1
'
]
}
}
return
{
'
tuple
'
:
[
setting
,
updatedArray
]
}
}
else
{
return
{
'
tuple
'
:
[
setting
,
value
]
}
}
...
...
This diff is collapsed.
Click to expand it.
src/views/settings/components/inputComponents/SpecificMultipleSelect.vue
+
5
−
3
View file @
8e1825ae
...
...
@@ -20,9 +20,11 @@
allow-create
class=
"input"
@
change=
"updateSetting($event, settingGroup.group, settingGroup.key, setting.key, setting.type)"
>
<el-option
value=
"strip"
label=
"strip"
/>
<el-option
value=
"auto-orient"
label=
"auto-orient"
/>
<el-option
value=
"implode"
label=
"implode"
/>
<el-option
value=
"strip"
/>
<el-option
value=
"auto-orient"
/>
<!-- eslint-disable -->
<el-option
value=
'
{"implode", "1"}'/>
<!-- eslint-enable -->
</el-select>
</div>
</
template
>
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment