Skip to content

Commit

Permalink
typo: InterestGroup
Browse files Browse the repository at this point in the history
  • Loading branch information
PeterJFB committed Apr 30, 2022
1 parent 9dc3997 commit 78c44c3
Show file tree
Hide file tree
Showing 4 changed files with 10 additions and 10 deletions.
2 changes: 1 addition & 1 deletion app/actions/GroupActions.js
Original file line number Diff line number Diff line change
Expand Up @@ -84,7 +84,7 @@ export function fetchAllWithType(type: string): Thunk<any> {
});
}

export function fetchRandomInterestgroups(): Thunk<any> {
export function fetchRandomInterestGroups(): Thunk<any> {
return callAPI({
types: Group.FETCH_RANDOM_INTERESTS,
endpoint: '/groups/random_interests/',
Expand Down
4 changes: 2 additions & 2 deletions app/reducers/frontpage.js
Original file line number Diff line number Diff line change
Expand Up @@ -5,14 +5,14 @@ import { sortBy } from 'lodash';
import { createSelector } from 'reselect';
import { selectArticles } from './articles';
import { selectEvents } from './events';
import { selectRandomInterestgroups } from './groups';
import { selectRandomInterestGroups } from './groups';

export default fetching(Frontpage.FETCH);

export const selectFrontpage = createSelector(
selectArticles,
selectEvents,
selectRandomInterestgroups,
selectRandomInterestGroups,
(articles, events, interestGroups) => {
articles = articles.map((article) => ({
...article,
Expand Down
2 changes: 1 addition & 1 deletion app/reducers/groups.js
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,7 @@ export const selectGroupsWithType = createSelector(
(groups, groupType) => groups.filter((g) => g.type === groupType)
);

export const selectRandomInterestgroups = createSelector(
export const selectRandomInterestGroups = createSelector(
(state) => state.groups.byId,
(state) => state.groups.randomInterestById,
(groupsById, groupIds) => {
Expand Down
12 changes: 6 additions & 6 deletions app/routes/overview/IndexRoute.js
Original file line number Diff line number Diff line change
Expand Up @@ -17,14 +17,14 @@ import {
} from 'app/reducers/feeds';
import { selectPinnedPolls } from 'app/reducers/polls';
import { votePoll } from 'app/actions/PollActions';
import { fetchRandomInterestgroups } from 'app/actions/GroupActions';
import { selectRandomInterestgroups } from 'app/reducers/groups';
import { fetchRandomInterestGroups } from 'app/actions/GroupActions';
import { selectRandomInterestGroups } from 'app/reducers/groups';

const mapStateToProps = (state) => ({
frontpage: selectFrontpage(state),
feed: selectFeedById(state, { feedId: 'personal' }),
shouldFetchQuote: isEmpty(selectRandomQuote(state)),
shouldFetchInterestgroups: isEmpty(selectRandomInterestgroups(state)),
shouldFetchInterestGroups: isEmpty(selectRandomInterestGroups(state)),
feedItems: selectFeedActivitesByFeedId(state, {
feedId: 'personal',
}),
Expand All @@ -41,13 +41,13 @@ export default compose(
// ),
connect(mapStateToProps, mapDispatchToProps),
prepare(
({ shouldFetchQuote, shouldFetchInterestgroups, loggedIn }, dispatch) =>
({ shouldFetchQuote, shouldFetchInterestGroups, loggedIn }, dispatch) =>
Promise.all([
loggedIn && shouldFetchQuote && dispatch(fetchRandomQuote()),
dispatch(fetchReadmes(loggedIn ? 4 : 1)),
loggedIn &&
shouldFetchInterestgroups &&
dispatch(fetchRandomInterestgroups()),
shouldFetchInterestGroups &&
dispatch(fetchRandomInterestGroups()),
]),
[],
{ awaitOnSsr: false }
Expand Down

0 comments on commit 78c44c3

Please sign in to comment.