Adding in Paul Carter's fixes/suggestions.