Changing the Primary Administrator First connect to SharePoint Online admin center $connection = Connect-PnPOnline -Url https://YourTenant-admin.sharepoint.com -Credentials (Get-Credential) -ReturnConnection Then get the Site $site = Get-PnPTenantSite -Url https://YourTenant.sharepoint.com/sites/SiteAlias -Connection $connection Then update the Owner (same as Primary Administrator) using the new Primary Administrators Email/UserPrincipalName. $site.Owner = “user@domain.com” $site.Update() $site.Context.ExecuteQuery() Verifying the Primary Administrator Connect to […]
Category: Code
Upgrading NPM on Windows
I recently had to update the NPM version on my laptop to a never version (because I wanted to use NPX – for avoiding globally installing and updating create-react-app). I started by downloading the latest LTS version of Node (which at the time of writing includes NPM version 5.6.0). Ran the installer and found Node to […]
Completing my Path at OpenClassrooms
I have for the last year been studying the Front-end Developer Path at OpenClassrooms. 2 days ago I got the last project approved and yesterday it was submitted to be judged by an academic jury. I’m now waiting for the jury’s feedback (which I should receive by June) and thought that now would be a […]
Use Array some() instead of forEach() if a break out is needed
When iterating an array with a need to break out at some point, I have always used the good old for loop instead of some other Array iteration variant. This is mainly due to the fact that .forEach() does not have a break out option – forcing the entire array to be iterated. But… while […]