aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/Wallabag/CoreBundle/Entity/User.php
diff options
context:
space:
mode:
Diffstat (limited to 'src/Wallabag/CoreBundle/Entity/User.php')
-rw-r--r--src/Wallabag/CoreBundle/Entity/User.php27
1 files changed, 27 insertions, 0 deletions
diff --git a/src/Wallabag/CoreBundle/Entity/User.php b/src/Wallabag/CoreBundle/Entity/User.php
index 193dfebc..ed5cfe53 100644
--- a/src/Wallabag/CoreBundle/Entity/User.php
+++ b/src/Wallabag/CoreBundle/Entity/User.php
@@ -92,6 +92,11 @@ class User implements AdvancedUserInterface, \Serializable
92 */ 92 */
93 private $entries; 93 private $entries;
94 94
95 /**
96 * @ORM\OneToOne(targetEntity="Config", mappedBy="user")
97 */
98 private $config;
99
95 public function __construct() 100 public function __construct()
96 { 101 {
97 $this->salt = md5(uniqid(null, true)); 102 $this->salt = md5(uniqid(null, true));
@@ -320,4 +325,26 @@ class User implements AdvancedUserInterface, \Serializable
320 { 325 {
321 return $this->isActive; 326 return $this->isActive;
322 } 327 }
328 /**
329 * Set config
330 *
331 * @param \Wallabag\CoreBundle\Entity\Config $config
332 * @return User
333 */
334 public function setConfig(\Wallabag\CoreBundle\Entity\Config $config = null)
335 {
336 $this->config = $config;
337
338 return $this;
339 }
340
341 /**
342 * Get config
343 *
344 * @return \Wallabag\CoreBundle\Entity\Config
345 */
346 public function getConfig()
347 {
348 return $this->config;
349 }
323} 350}