Skip to content

Commit eca92b1

Browse files
committed
Removing setting the visibility as this is already being done inside the Create method of the GroupsUtility as well and thus redundant
1 parent 8c6d67d commit eca92b1

File tree

1 file changed

+0
-5
lines changed

1 file changed

+0
-5
lines changed

src/Commands/Microsoft365Groups/NewMicrosoft365Group.cs

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -175,11 +175,6 @@ protected override void ExecuteCmdlet()
175175

176176
var group = Microsoft365GroupsUtility.Create(GraphRequestHelper, newGroup, CreateTeam, LogoPath, Owners, Members, HideFromAddressLists, HideFromOutlookClients, Labels);
177177

178-
if (ParameterSpecified(nameof(HideFromAddressLists)) || ParameterSpecified(nameof(HideFromOutlookClients)))
179-
{
180-
Microsoft365GroupsUtility.SetVisibility(GraphRequestHelper, group.Id.Value, HideFromAddressLists, HideFromOutlookClients);
181-
}
182-
183178
var updatedGroup = Microsoft365GroupsUtility.GetGroup(GraphRequestHelper, group.Id.Value, true, false, false, true);
184179

185180
WriteObject(updatedGroup);

0 commit comments

Comments
 (0)