I have this script that I have heavily modified to accept inventory and to give that inventory to access list users. The entire script is working perfectly as intended except I receive the following message:
Unable to give inventory: 'No item named ''.'.
Missing inventory item ''.
As you can it doesn't specify what it thinks it's missing. Here's the script portion causing me to go bald

CODE
touch_start(integer total_number)
{
integer i;
for (i=0;i<total_number;i++)
{
key target = llDetectedKey(i);
if(llListFindList(authaccess, (list)llKey2Name(llDetectedKey(0))) != -1)
{
list inventory_types = [INVENTORY_BODYPART,INVENTORY_CLOTHING,INVENTORY_LANDMARK,INVENTORY_NOTECARD,INVENTORY_OBJECT,INVENTORY_SCRIPT,INVENTORY_SOUND,INVENTORY_TEXTURE];
integer inventory_count = llGetListLength(inventory_types);
integer j;
integer k;
integer t;
integer typecount;
string myname = llGetScriptName();
string objectname;
for (j=0; j<inventory_count;j++)
{
t = llList2Integer(inventory_types,j); // Get next Inventory type
typecount = llGetInventoryNumber(t); // How many of that type in inventory
if (typecount > 0)
{
for (k=0; k<typecount;k++)
{
objectname = llGetInventoryName(t,k);
if (objectname != myname) // Dont give out the script
{
if (objectname != (string)"AppBoxConfig") //Dont give out config card
{
if (objectname != application) //Dont give out information card
{
llGiveInventory(target,objectname);
llRemoveInventory(objectname);
}
}
}
}
}
}
}
else
{
llGiveInventory((llDetectedKey(0)),application); //Give unauthorized users information card
}
}
}CODE

