diff --git a/onepassword/data_source_onepassword_item.go b/onepassword/data_source_onepassword_item.go index dc1a16bf..719d4e42 100644 --- a/onepassword/data_source_onepassword_item.go +++ b/onepassword/data_source_onepassword_item.go @@ -214,10 +214,6 @@ func dataSourceOnepasswordItemRead(ctx context.Context, data *schema.ResourceDat data.Set("username", f.Value) case "PASSWORD": data.Set("password", f.Value) - case "CREDENTIAL": - if f.ID == "credential" { - data.Set("password", f.Value) - } case "NOTES": data.Set("note_value", f.Value) default: @@ -225,6 +221,10 @@ func dataSourceOnepasswordItemRead(ctx context.Context, data *schema.ResourceDat data.Set(strings.ToLower(f.Label), f.Value) } } + + if f.ID == "credential" { + data.Set("password", f.Value) + } } return nil