mirror of
https://github.com/Readarr/Readarr.git
synced 2026-04-20 21:54:25 -04:00
New: Author folder hint when selecting a root folder while adding a new author
(cherry picked from commit dd09f31abb4dd3f699bcff0a47577075300c70ee) Fix AuthorFolderAsRootFolderValidator (cherry picked from commit 0ce81e1ab69d43fde382cc4ae22cd46fe626dea7)
This commit is contained in:
@@ -10,13 +10,15 @@ import AddNewItem from './AddNewItem';
|
||||
function createMapStateToProps() {
|
||||
return createSelector(
|
||||
(state) => state.search,
|
||||
(state) => state.authors.items.length,
|
||||
(state) => state.router.location,
|
||||
(search, location) => {
|
||||
(search, existingAuthorsCount, location) => {
|
||||
const { params } = parseUrl(location.search);
|
||||
|
||||
return {
|
||||
...search,
|
||||
term: params.term,
|
||||
...search
|
||||
hasExistingAuthors: existingAuthorsCount > 0
|
||||
};
|
||||
}
|
||||
);
|
||||
|
||||
Reference in New Issue
Block a user