fixed spelling and ported over from web client