Skip to content

Commit

Permalink
Compatible with older versions
Browse files Browse the repository at this point in the history
  • Loading branch information
shuhanliu committed Jul 1, 2024
1 parent f8fc470 commit cf69800
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion pkg/inject/pkg/kube/inject/apply/javaagent/patch.go
Original file line number Diff line number Diff line change
Expand Up @@ -150,7 +150,7 @@ func (pb *PodPatchBuilder) handleJavaAgentInit(opt *inject.PatchOptions, pod *co

defaultProperties := make(map[string]string)

if validVersions[annonations[customJavaAgentVersion]] {
if val, ok := annonations[customJavaAgentVersion]; ok && (validVersions[val] && val != "") {
kubeClient := opt.KubeClient
pluginCm, err := kubeClient.CoreV1().ConfigMaps(util.RootNamespace).Get(context.Background(),
"plugin-default.properties", metav1.GetOptions{})
Expand Down

0 comments on commit cf69800

Please sign in to comment.