Reading session variables Auth allowed methods

<?php
namespace App\Controller;

use App\Controller\AppController;
use Cake\Collection\Collection;
use Cake\Event\Event;

class ArticlesController extends AppController
{
    public $checkDataMember = null;
    public function initialize()
    {
        parent::initialize();

        $this->Auth->allow();
    }

    public function home() {
        $this->getRequest()->getSession()->write('check', 'Session123');
    }


    public function dashboard() {
       $this->getRequest()->getSession()->read('check'); // Not getting the value here
   }

}