aboutsummaryrefslogtreecommitdiffstats
path: root/perllib/FixMyStreet/DB/Result/User.pm
diff options
context:
space:
mode:
authorMatthew Somerville <matthew@mysociety.org>2020-06-10 14:29:35 +0100
committerMatthew Somerville <matthew@mysociety.org>2020-06-30 11:24:57 +0100
commit51eae76dd663d23c1f4bb1e809e9c258e800cb73 (patch)
treefc0bcf5c37119c302908319ec02abf7c8123f94b /perllib/FixMyStreet/DB/Result/User.pm
parent3c98b8f4dbe7085d52887deff90681db552fb580 (diff)
Only show access tokens once, and store hashed.
Diffstat (limited to 'perllib/FixMyStreet/DB/Result/User.pm')
-rw-r--r--perllib/FixMyStreet/DB/Result/User.pm5
1 files changed, 5 insertions, 0 deletions
diff --git a/perllib/FixMyStreet/DB/Result/User.pm b/perllib/FixMyStreet/DB/Result/User.pm
index 49338f245..e5be14abf 100644
--- a/perllib/FixMyStreet/DB/Result/User.pm
+++ b/perllib/FixMyStreet/DB/Result/User.pm
@@ -179,6 +179,11 @@ sub check_password {
}
}
+sub access_token {
+ my $self = shift;
+ return $self->get_extra_metadata('access_token');
+}
+
around password => sub {
my ($orig, $self) = (shift, shift);
if (@_) {