Abhi #0 fixing the error in trimmed function