Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[WFCORE-6445] Update ModuleSpecification.getMutableUserDependencies #5735

Merged
merged 1 commit into from
Oct 31, 2023
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,6 @@ public class ModuleSpecification extends SimpleAttachable {
private final List<ModuleDependency> userDependencies = new ArrayList<>();
/**
* Set view of user dependencies, used to prevent duplicates in the userDependencies list.
* TODO update getMutableUserDependencies and replace the list with this.
*/
private final Set<ModuleDependency> userDependenciesSet = new HashSet<>();

Expand Down Expand Up @@ -235,11 +234,11 @@ public List<ModuleDependency> getUserDependencies() {
/**
* Gets a modifiable view of the user dependencies list.
*
* @return The user dependencies TODO change the return type to Collection and return a Set
* @return The user dependencies
*/
public List<ModuleDependency> getMutableUserDependencies() {
public Collection<ModuleDependency> getMutableUserDependencies() {
allDependencies = null;
return userDependencies;
return userDependenciesSet;
}

public void addResourceLoader(final ResourceLoaderSpec resourceLoader) {
Expand Down