When trying to create a pool with the following options I expect to have 1 object available at all times and the object not to be destroyed when it times out.
options {
"refreshIdle": false,
"min": 1,
"max": 1
}
Instead the object is destroyed when the timeout is hit. This happens since the Pool constructor will assume the min should always be at least 1 less than the max. The options above end up resulting in a max of 1 and a min of 0
A simple solution could be to remove the max-1 assumption for the min value.