From 4f48cb75421f2c8a47961b616bc03a8e8d680da8 Mon Sep 17 00:00:00 2001 From: Eran Turgeman Date: Thu, 3 Aug 2023 13:03:29 +0300 Subject: [PATCH] switch a use of pointer to non-pointer --- build/utils/yarn.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/build/utils/yarn.go b/build/utils/yarn.go index d4755811..71cf6879 100644 --- a/build/utils/yarn.go +++ b/build/utils/yarn.go @@ -184,7 +184,7 @@ func buildYarnV1DependencyMap(packageInfo *PackageInfo, responseStr string) (dep // Adding child dependencies for each dependency for _, curDependency := range depTree.Data.DepTree { - dependency := *(dependenciesMap[curDependency.Name]) + dependency := dependenciesMap[curDependency.Name] for _, subDep := range curDependency.Dependencies { subDepName, _, err := splitNameAndVersion(subDep.DependencyName) @@ -193,7 +193,7 @@ func buildYarnV1DependencyMap(packageInfo *PackageInfo, responseStr string) (dep } dependency.Details.Dependencies = append(dependency.Details.Dependencies, YarnDependencyPointer{subDep.DependencyName, packNameToFullName[subDepName]}) } - dependenciesMap[curDependency.Name] = &dependency + dependenciesMap[curDependency.Name] = dependency } rootProject := buildYarn1Root(packageInfo, &packNameToFullName)