Changed code to use  instead of ->getID() for keywords since this may not be set for new applications