Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
pleroma-fe
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
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
pleroma-fe
Commits
f18f8774
Commit
f18f8774
authored
8 years ago
by
lain
Browse files
Options
Downloads
Patches
Plain Diff
Also add retweeted users to user store.
parent
7b5a30db
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
src/modules/users.js
+3
-1
3 additions, 1 deletion
src/modules/users.js
with
3 additions
and
1 deletion
src/modules/users.js
+
3
−
1
View file @
f18f8774
import
timelineFetcher
from
'
../services/timeline_fetcher/timeline_fetcher.service.js
'
import
backendInteractorService
from
'
../services/backend_interactor_service/backend_interactor_service.js
'
import
{
map
,
each
,
find
,
merge
}
from
'
lodash
'
import
{
compact
,
map
,
each
,
find
,
merge
}
from
'
lodash
'
// TODO: Unify with mergeOrAdd in statuses.js
export
const
mergeOrAdd
=
(
arr
,
item
)
=>
{
...
...
@@ -44,7 +44,9 @@ const users = {
actions
:
{
addNewStatuses
(
store
,
{
statuses
})
{
const
users
=
map
(
statuses
,
'
user
'
)
const
retweetedUsers
=
compact
(
map
(
statuses
,
'
retweeted_status.user
'
))
store
.
commit
(
'
addNewUsers
'
,
users
)
store
.
commit
(
'
addNewUsers
'
,
retweetedUsers
)
},
loginUser
(
store
,
userCredentials
)
{
const
commit
=
store
.
commit
...
...
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