Fixed wrong use of optional that should have been key.