Inserted the definitely typed when.js code into the current defition as Promise2.  Removed some old, unused functions from MetaHub.