1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
|
<?php /** * @package Freemius * @copyright Copyright (c) 2015, Freemius, Inc. * @license https://www.gnu.org/licenses/gpl-3.0.html GNU General Public License Version 3 * @since 1.0.3 */
if ( ! defined( 'ABSPATH' ) ) { exit; }
class FS_User extends FS_Scope_Entity {
#region Properties
/** * @var string */ public $email; /** * @var string */ public $first; /** * @var string */ public $last; /** * @var bool */ public $is_verified; /** * @author Leo Fajardo (@leorw) * @since 2.3.0 * * @var bool */ public $is_beta; /** * @var string|null */ public $customer_id; /** * @var float */ public $gross;
#endregion Properties
/** * @param object|bool $user */ function __construct( $user = false ) { parent::__construct( $user ); }
function get_name() { return trim( ucfirst( trim( is_string( $this->first ) ? $this->first : '' ) ) . ' ' . ucfirst( trim( is_string( $this->last ) ? $this->last : '' ) ) ); }
function is_verified() { return ( isset( $this->is_verified ) && true === $this->is_verified ); }
/** * @author Leo Fajardo (@leorw) * @since 2.3.0 * * @return bool */ function is_beta() { return ( isset( $this->is_beta ) && true === $this->is_beta ); }
static function get_type() { return 'user'; } }
|