mirror of
https://github.com/Readarr/Readarr.git
synced 2026-04-26 22:46:37 -04:00
Fixed: Editing provider/profile settings appearing to affect wrong item
This commit is contained in:
@@ -1,6 +1,5 @@
|
||||
import PropTypes from 'prop-types';
|
||||
import React, { Component } from 'react';
|
||||
import sortByName from 'Utilities/Array/sortByName';
|
||||
import { icons } from 'Helpers/Props';
|
||||
import FieldSet from 'Components/FieldSet';
|
||||
import Card from 'Components/Card';
|
||||
@@ -68,7 +67,7 @@ class ImportLists extends Component {
|
||||
>
|
||||
<div className={styles.lists}>
|
||||
{
|
||||
items.sort(sortByName).map((item) => {
|
||||
items.map((item) => {
|
||||
return (
|
||||
<ImportList
|
||||
key={item.id}
|
||||
|
||||
@@ -2,18 +2,16 @@ import PropTypes from 'prop-types';
|
||||
import React, { Component } from 'react';
|
||||
import { connect } from 'react-redux';
|
||||
import { createSelector } from 'reselect';
|
||||
import sortByName from 'Utilities/Array/sortByName';
|
||||
import createSortedSectionSelector from 'Store/Selectors/createSortedSectionSelector';
|
||||
import { fetchImportLists, deleteImportList } from 'Store/Actions/settingsActions';
|
||||
import { fetchRootFolders } from 'Store/Actions/rootFolderActions';
|
||||
import ImportLists from './ImportLists';
|
||||
|
||||
function createMapStateToProps() {
|
||||
return createSelector(
|
||||
(state) => state.settings.importLists,
|
||||
(importLists) => {
|
||||
return {
|
||||
...importLists
|
||||
};
|
||||
}
|
||||
createSortedSectionSelector('settings.importLists', sortByName),
|
||||
(importLists) => importLists
|
||||
);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user