Skip to content

Commit 3a3e1d1

Browse files
Update files and fix some issues
1 parent f7cccae commit 3a3e1d1

8 files changed

Lines changed: 10 additions & 6 deletions

File tree

.gitignore

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
.env
2-
.env.dev
2+
dev.env
33
discordguild.php
44
f.php
55
test.php
@@ -23,3 +23,5 @@ buildpush.sh
2323
html/install-php-extensions
2424
composer.lock
2525
info.php
26+
*.env
27+
!example.*.env

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
# DevCord Devmarkt
22

33
## setup dev environment
4-
- copy .env.dev.example to .env.dev
4+
- copy example.dev.env to dev.env
55
- enter all properties
66
- add the bot to your server
77
- run `docker compose -f compose.debug.yaml up`

compose.debug.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,4 +23,4 @@ services:
2323
MYSQL_PASSWORD: test
2424
BOT_REDIRECT_URI: http://localhost:8080/login.php?
2525
BOT_BASE_URI: http://localhost:8080
26-
env_file: .env.dev
26+
env_file: dev.env
File renamed without changes.
File renamed without changes.

php/devmarkt.inc.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -21,12 +21,12 @@
2121
$devmarktChannel = getenv('GUILD_DEVMARKT_CHANNEL');
2222

2323
if ($login->isBlocked()) {
24-
header('Location: index.php');
24+
header('Location: ' . $base_url . '/index.php');
2525
}
2626

2727
if ($login->isOnCoolDown()
2828
&& !($login->isModerator())) {
29-
header('Location: index.php');
29+
header('Location: ' . $base_url . '/index.php');
3030
}
3131

3232
if (!(isset($_POST['titel'], $_POST['type'], $_POST['beschreibung'], $_POST['color']))) {

public/devmarkt.inc.php

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
<?php
2+
include_once('../php/devmarkt.inc.php');

public/index.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -129,7 +129,7 @@
129129

130130
?>
131131

132-
<form id="form" method="POST" action="php/devmarkt.inc.php">
132+
<form id="form" method="POST" action="devmarkt.inc.php">
133133

134134
<?php
135135

0 commit comments

Comments
 (0)