Apply ad permission to multiple databases at once

Apply ad permission on multiple databases at once using these steps:
 
scenario: customer wants admin acct to have receive-as permissions on all databases that start with on
 
soln: use this powershell one liner
 
get-mailboxdatabase | where-object {$_.identity -like "on*"} | Add-ADPermission -user "admin" -accessrights extendedright -extendedrights receive-as, ms-exch-store-admin -inheritancetype 'All'