Skip to content
Next
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Switch to GitLab Next
Sign in / Register
Toggle navigation
Minds Backend - Engine
Project
Project
Details
Activity
Releases
Dependency List
Cycle Analytics
Insights
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Locked Files
Issues
157
Issues
157
List
Boards
Labels
Service Desk
Milestones
Merge Requests
48
Merge Requests
48
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Packages
Packages
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Minds
Minds Backend - Engine
Commits
28d78fe8
Commit
28d78fe8
authored
13 minutes ago
by
Mark Harding
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
(chore): move back to cassandra counters
parent
4c745aae
chore/cockroach-silent
No related merge requests found
Pipeline
#68851665
pending with stages
Changes
1
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
21 additions
and
17 deletions
+21
-17
Counters.php
Core/Notification/Counters.php
+21
-17
No files found.
Core/Notification/Counters.php
View file @
28d78fe8
...
...
@@ -50,7 +50,7 @@ class Counters
*/
public
function
getCount
(
array
$options
=
[])
{
//
return Helpers\Counters::get($this->user, 'notifications:count', false);
return
Helpers\Counters
::
get
(
$this
->
user
,
'notifications:count'
,
false
);
// TODO: Remove below once settled
...
...
@@ -104,21 +104,25 @@ class Counters
// TODO: Remove below once settled
$query
=
"BEGIN;
UPDATE notifications
SET read_timestamp = NOW()
WHERE to_guid = ?
ORDER BY created_timestamp DESC
LIMIT 6
RETURNING NOTHING;
COMMIT;"
;
$params
=
[
(
int
)
$this
->
user
->
getGuid
(),
];
$statement
=
$this
->
sql
->
prepare
(
$query
);
$statement
->
execute
(
$params
);
try
{
$query
=
"BEGIN;
UPDATE notifications
SET read_timestamp = NOW()
WHERE to_guid = ?
ORDER BY created_timestamp DESC
LIMIT 6
RETURNING NOTHING;
COMMIT;"
;
$params
=
[
(
int
)
$this
->
user
->
getGuid
(),
];
$statement
=
$this
->
sql
->
prepare
(
$query
);
$statement
->
execute
(
$params
);
}
catch
(
\Exception
$e
)
{
}
}
}
This diff is collapsed.
Click to expand it.
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment