/** * Gets the word that was stored in session data * @return string the retrieved and decoded word */ protected function getWord() { // Get cypher from session data $cypher = $this->word->getWordCypher(); // Decrypt the word $decryptedString = EncryptionUtility::decrypt($cypher); return implode('-', preg_split('//', $decryptedString, -1, PREG_SPLIT_NO_EMPTY)); }