Add configurable ObjectId tester in JObjectParser #1277

Merged
merged 1 commit into from Jun 13, 2012

Projects

None yet

2 participants

Member
eltimn commented Jun 8, 2012

https://groups.google.com/d/topic/liftweb/fXDixRS1H4M/discussion

Currently, all Strings are tested to see if they are valid ObjectIds. This can cause problems if that's not what's needed. Allow configuration via a FactoryMaker.

object MongoDB extends Factory {

  val jobjectParserObjectIdTester = new FactoryMaker[String => Boolean](s => ObjectId.isValid(s)) {}

}
@eltimn eltimn was assigned Jun 7, 2012
@dpp dpp merged commit 85b8293 into master Jun 13, 2012
@eltimn eltimn deleted the tcn_issue_1277 branch Nov 6, 2013
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment