Issue Bug Closed

#18589Split does not work with returnKey = 0

Dirk Weise 04/08/08, 21:38 updated 08/06/10, 13:20

Description

Problem:
You can’t use split to return the first element of a splited value. It will return the whole string instead.
split {
token.char = 10
returnKey = 0
}

Checking a var that contains a zero in an if statement always resolves to false….

Resolution:
Checking with is_numeric().
See attached patch, it’s a no brainer.
Will report to core list.

(issue imported from #M8064)

Reviews 0

No change resolves or names this issue in its commit message, and no comment links one.