n2cms/n2cms — pull request #194 by johants (2013-05-29 22:59:52+00:00)
Title: Fix the runtime issue with GetDataItemsByIds method in EditableItemSelectionAttribute

Fix the issue with GetDataItemsByIds method in EditableItemSelectionAttribute.

The issue is when Parameter.In is being called, since the second parameter is "param object[] anyOf" it takes the integer array as the first item in the object[] instead of converting it to an array of objects that causes runtime error.

More information about param object[] in the following page, http://msdn.microsoft.com/en-us/library/w5zay9db.aspx

Please note that the diff file is big because it is showing some whitespace changes, the meat of the change is the following line.

var items = Engine.Content.Search.Repository.Find(Parameter.In("ID", ids.Select(id => (object)id).ToArray()));