Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
Feeds
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container Registry
Model registry
Operate
Environments
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
TeDomum
Feeds
Commits
ebf16a36
Commit
ebf16a36
authored
4 years ago
by
Andrew Dolgov
Browse files
Options
Downloads
Patches
Plain Diff
remove a bunch of return type hints that didn't quite fit
parent
ef8c3abd
No related branches found
Branches containing commit
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
classes/userhelper.php
+4
-4
4 additions, 4 deletions
classes/userhelper.php
with
4 additions
and
4 deletions
classes/userhelper.php
+
4
−
4
View file @
ebf16a36
...
...
@@ -143,7 +143,7 @@ class UserHelper {
}
static
function
get_user_ip
()
:
string
{
static
function
get_user_ip
()
{
foreach
([
"HTTP_X_REAL_IP"
,
"REMOTE_ADDR"
]
as
$hdr
)
{
if
(
isset
(
$_SERVER
[
$hdr
]))
return
$_SERVER
[
$hdr
];
...
...
@@ -152,7 +152,7 @@ class UserHelper {
return
null
;
}
static
function
get_login_by_id
(
int
$id
)
:
string
{
static
function
get_login_by_id
(
int
$id
)
{
$pdo
=
Db
::
pdo
();
$sth
=
$pdo
->
prepare
(
"SELECT login FROM ttrss_users WHERE id = ?"
);
...
...
@@ -165,7 +165,7 @@ class UserHelper {
return
null
;
}
static
function
find_user_by_login
(
string
$login
)
:
int
{
static
function
find_user_by_login
(
string
$login
)
{
$pdo
=
Db
::
pdo
();
$sth
=
$pdo
->
prepare
(
"SELECT id FROM ttrss_users WHERE
...
...
@@ -264,7 +264,7 @@ class UserHelper {
return
false
;
}
static
function
get_otp_secret
(
int
$owner_uid
,
bool
$show_if_enabled
=
false
)
:
string
{
static
function
get_otp_secret
(
int
$owner_uid
,
bool
$show_if_enabled
=
false
)
{
$sth
=
Db
::
pdo
()
->
prepare
(
"SELECT salt, otp_enabled FROM ttrss_users WHERE id = ?"
);
$sth
->
execute
([
$owner_uid
]);
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment