Skip to content

Commit cd26522

Browse files
committed
Shut up some errors
fixes #52
1 parent eed1ade commit cd26522

File tree

3 files changed

+3
-3
lines changed

3 files changed

+3
-3
lines changed

misc/server-lookup-misc.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -363,7 +363,7 @@ function generate_html_extserverinfo($server)
363363
<table>
364364
<tr>
365365
<th>Cert Fingerprint</th>
366-
<td><?php echo "<span class=\"badge rounded-pill badge-info\">".htmlspecialchars($server->tls->certfp)."</span>"; ?></td>
366+
<td><?php echo (isset($server->tls->certfp) ? "<span class=\"badge rounded-pill badge-info\">".htmlspecialchars($server->tls->certfp). "</span>" : "none"); ?></td>
367367
</tr><tr>
368368
<th>TLS Cipher</th>
369369
<td><?php echo "<span class=\"badge rounded-pill badge-info\">".htmlspecialchars($server->tls->cipher)."</span>"; ?></td>

misc/user-lookup-misc.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,7 @@ function generate_html_whois($user)
4040
</tr><tr>
4141
<th>IP</th>
4242
<td colspan="2">
43-
<code><?php echo htmlspecialchars($user->ip); ?></code>
43+
<code><?php echo (isset($user->ip) ? htmlspecialchars($user->ip) : "255.255.255.255"); ?></code>
4444
<?php
4545
if (strlen($cc))
4646
{

settings/general.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -106,7 +106,7 @@ function _ce($can){
106106
<div class="card m-1" style="padding-left:20px;padding-right:20px;padding-top:5px;padding-bottom:10px;max-width:fit-content">
107107
<h6>Debug Mode</h6>
108108
<div class="custom-control custom-switch">
109-
<input name="debug_mode" type="checkbox" class="custom-control-input" id="debug_mode" <?php _ce($canEdit); echo ($config['debug'] == true) ? " checked" : ""; ?>>
109+
<input name="debug_mode" type="checkbox" class="custom-control-input" id="debug_mode" <?php _ce($canEdit); echo (get_config('debug') == true) ? " checked" : ""; ?>>
110110
<label class="custom-control-label" for="debug_mode">Enable Debug Mode (Developers Only)</label>
111111
</div>
112112
<i>Enabling this will likely make your webpanel more difficult to use</i>

0 commit comments

Comments
 (0)