added in trim of extra spaces