Skip to content

Commit 19b6c60

Browse files
committed
add User Statistics changes
1 parent 223550d commit 19b6c60

File tree

1 file changed

+14
-0
lines changed

1 file changed

+14
-0
lines changed

src/Users/User.php

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -27,6 +27,11 @@ class User extends LazyResource
2727
*/
2828
protected $_contact_info;
2929

30+
/**
31+
* @var UserStatistics
32+
*/
33+
protected $_user_statistics;
34+
3035
/**
3136
* @var Loans
3237
*/
@@ -96,6 +101,14 @@ public function getContactInfo()
96101
return $this->init()->_contact_info;
97102
}
98103

104+
/**
105+
* Get the user's statistics info.
106+
*/
107+
public function getStatistics()
108+
{
109+
return $this->init()->_user_statistics;
110+
}
111+
99112
/**
100113
* Save the user
101114
*
@@ -128,6 +141,7 @@ protected function onData($data)
128141
{
129142
$this->_identifiers = UserIdentifiers::make($this->client, $data);
130143
$this->_contact_info = ContactInfo::make($this->client, $data->contact_info);
144+
$this->_user_statistics = UserStatistics::make($this->client, $data->user_statistic);
131145
}
132146

133147
/**

0 commit comments

Comments
 (0)