log.debug("in: " + result);
Bug bug = (Bug)object(context);
// AK: this is just an illustration
if(bug != null) {
result = choiceByRemovingKeys(new NSArray("edit"), result);
if(!bug.state().equals(State.ANALYZE)) {
result = choiceByRemovingKeys(new NSArray("delete"), result);
}
if(!bug.state().equals(State.CLOSED)) {
result = choiceByRemovingKeys(new NSArray(new Object[] {"reopen"}), result);
}