jsinq bug: .min/.max on single-element list

Hi,

  Thanks for your excellent jsinq library. I have found a bug, if you
run .min or .max on a list with only one element the result selector is
not applied, while in C# `new List<int>() { 1 }.Min(x => x + 1)` you get
`2`, with jsinq `new jsinq.Enumerable([1]).min(function(x){ return x+1
})` you get `1` instead. A solution would be applying .select with the
result selector and then returning the min/max of the result.

regards,
-- 
Björn Höhrmann · mailto:bjoern@hoehrmann.de · http://bjoern.hoehrmann.de
Am Badedeich 7 · Telefon: +49(0)160/4415681 · http://www.bjoernsworld.de
25899 Dagebüll · PGP Pub. KeyID: 0xA4357E78 · http://www.websitedev.de/ 

Received on Sunday, 27 February 2011 22:42:17 UTC