Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
Castopod
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package registry
Container Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
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
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Johannes Zellner
Castopod
Commits
33f1b91d
Unverified
Commit
33f1b91d
authored
3 years ago
by
Yassine Doghri
Browse files
Options
Downloads
Patches
Plain Diff
fix: update condition in home controller to redirect to install page
parent
eb74e81c
No related branches found
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
app/Controllers/HomeController.php
+2
-3
2 additions, 3 deletions
app/Controllers/HomeController.php
with
2 additions
and
3 deletions
app/Controllers/HomeController.php
+
2
−
3
View file @
33f1b91d
...
@@ -18,10 +18,9 @@ class HomeController extends BaseController
...
@@ -18,10 +18,9 @@ class HomeController extends BaseController
{
{
public
function
index
():
RedirectResponse
|
string
public
function
index
():
RedirectResponse
|
string
{
{
$connections
=
\CodeIgniter\Database\Config
::
getConnections
();
$db
=
db_connect
();
$db
=
db_connect
();
if
(
$
connections
===
[]
||
!
$db
->
tableExists
(
'podcasts'
))
{
if
(
$
db
->
getDatabase
()
===
''
||
!
$db
->
tableExists
(
'podcasts'
))
{
//
Cannot connect to the databa
se or c
an
not find the podcasts table
//
Database connection has not been
se
t
or c
ould
not find the podcasts table
// Redirecting to install page because it is likely that Castopod Host has not been installed yet.
// Redirecting to install page because it is likely that Castopod Host has not been installed yet.
// NB: as base_url wouldn't have been defined here, redirect to install wizard manually
// NB: as base_url wouldn't have been defined here, redirect to install wizard manually
$route
=
Services
::
routes
()
->
reverseRoute
(
'install'
);
$route
=
Services
::
routes
()
->
reverseRoute
(
'install'
);
...
...
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