Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
S
syncEnrollments
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Yeray Santana Hualde
syncEnrollments
Commits
a77196db
Commit
a77196db
authored
Apr 06, 2012
by
Taylor Otwell
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
cleaning up code.
parent
8a687053
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
3 additions
and
4 deletions
+3
-4
database.php
laravel/cache/drivers/database.php
+1
-1
file.php
laravel/cache/drivers/file.php
+2
-3
No files found.
laravel/cache/drivers/database.php
View file @
a77196db
...
@@ -75,7 +75,7 @@ class Database extends Driver {
...
@@ -75,7 +75,7 @@ class Database extends Driver {
$expiration
=
$this
->
expiration
(
$minutes
);
$expiration
=
$this
->
expiration
(
$minutes
);
// To update the value, we'll first attempt an insert against the
// To update the value, we'll first attempt an insert against the
// database and if we catch an exception
,
we'll assume that the
// database and if we catch an exception we'll assume that the
// primary key already exists in the table and update.
// primary key already exists in the table and update.
try
try
{
{
...
...
laravel/cache/drivers/file.php
View file @
a77196db
...
@@ -42,9 +42,8 @@ class File extends Driver {
...
@@ -42,9 +42,8 @@ class File extends Driver {
if
(
!
file_exists
(
$this
->
path
.
$key
))
return
null
;
if
(
!
file_exists
(
$this
->
path
.
$key
))
return
null
;
// File based caches store have the expiration timestamp stored in
// File based caches store have the expiration timestamp stored in
// UNIX format prepended to their contents. This timestamp is then
// UNIX format prepended to their contents. We'll compare the
// extracted and removed when the cache is read to determine if
// timestamp to the current time when we read the file.
// the file is still valid.
if
(
time
()
>=
substr
(
$cache
=
file_get_contents
(
$this
->
path
.
$key
),
0
,
10
))
if
(
time
()
>=
substr
(
$cache
=
file_get_contents
(
$this
->
path
.
$key
),
0
,
10
))
{
{
return
$this
->
forget
(
$key
);
return
$this
->
forget
(
$key
);
...
...
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