<commit_before><?php
namespace Zf1auth;

/**
 * Class FacebookSessionPersistentDataHandler
 *
 * @package Facebook
 */
class Zf1auth_PersistentDataHandler implements \Facebook\PersistentData\PersistentDataInterface
{
    /**
     * @var string Prefix to use for session variables.
     */
    protected $sessionPrefix = 'Zf1auth_facebook';
    protected $_ses = null;

    /**
     * Init the session handler.
     *
     * @param boolean $enableSessionCheck
     *
     * @throws FacebookSDKException
     */
    public function __construct($enableSessionCheck = true)
    {
       $this->_initSes();
    }
    
    protected function _initSes()
    {
      $this->_ses = new \Zend_Session_Namespace($this->sessionPrefix, true);
    }

    /**
     * @inheritdoc
     */
    public function get($key)
    {
      return $this->_ses->{$key};
    }

    /**
     * @inheritdoc
     */
    public function set($key, $value)
    {
      $this->_ses->{$key} = $value;
    }
}<commit_msg>Added log<commit_after><?php
namespace Zf1auth;

use Facebook;

/**
 * Class FacebookSessionPersistentDataHandler
 *
 * @package Facebook
 */
class Zf1auth_PersistentDataHandler implements Facebook\PersistentData\PersistentDataInterface
{
    /**
     * @var string Prefix to use for session variables.
     */
    protected $sessionPrefix = 'Zf1auth_facebook';
    protected $_ses = null;

    /**
     * Init the session handler.
     *
     * @param boolean $enableSessionCheck
     *
     * @throws FacebookSDKException
     */
    public function __construct($enableSessionCheck = true)
    {
       $this->_initSes();
    }
    
    protected function _initSes()
    {
      $this->_ses = new \Zend_Session_Namespace($this->sessionPrefix, false);
    }

    /**
     * @inheritdoc
     */
    public function get($key)
    {
      return $this->_ses->{$key};
    }

    /**
     * @inheritdoc
     */
    public function set($key, $value)
    {
      $log = Zend_Registry::get('log');
      
      $log->log("Setting key '$key' to value '$value'", \Zend_Log::DEBUG);
      
      $this->_ses->{$key} = $value;
    }
}
{'fraction_non_alphanumeric': 0.1305792972459639, 'fraction_numerical': 0.002849002849002849, 'mean_word_length': 2.4204545454545454, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 18, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 9, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '1869485', 'n_tokens_mistral': 644, 'n_tokens_neox': 635, 'n_words': 130}