Fix Users Page crash by handling missing search params gracefully
This commit is contained in:
27
nginx_admin_config
Normal file
27
nginx_admin_config
Normal file
@@ -0,0 +1,27 @@
|
||||
server {
|
||||
server_name admin.prototype.eventifyplus.com;
|
||||
|
||||
root /var/www/admin.prototype.eventifyplus.com;
|
||||
index index.html;
|
||||
|
||||
location / {
|
||||
try_files $uri $uri/ /index.html;
|
||||
}
|
||||
|
||||
listen 443 ssl; # managed by Certbot
|
||||
ssl_certificate /etc/letsencrypt/live/admin.prototype.eventifyplus.com/fullchain.pem; # managed by Certbot
|
||||
ssl_certificate_key /etc/letsencrypt/live/admin.prototype.eventifyplus.com/privkey.pem; # managed by Certbot
|
||||
include /etc/letsencrypt/options-ssl-nginx.conf; # managed by Certbot
|
||||
ssl_dhparam /etc/letsencrypt/ssl-dhparams.pem; # managed by Certbot
|
||||
|
||||
}
|
||||
server {
|
||||
if ($host = admin.prototype.eventifyplus.com) {
|
||||
return 301 https://$host$request_uri;
|
||||
} # managed by Certbot
|
||||
|
||||
|
||||
listen 80;
|
||||
server_name admin.prototype.eventifyplus.com;
|
||||
return 404; # managed by Certbot
|
||||
}
|
||||
@@ -26,7 +26,7 @@ import { UserDetailSheet } from "./UserDetailSheet";
|
||||
export function UserBaseTab() {
|
||||
// --- State (URL Params) ---
|
||||
const [searchQuery, setSearchQuery] = useQueryState('q', parseAsString.withDefault(''));
|
||||
const [minSpent, setMinSpent] = useQueryState('minSpent', parseAsInteger);
|
||||
const [minSpent, setMinSpent] = useQueryState('minSpent', parseAsInteger.withDefault(0));
|
||||
const [statusFilter, setStatusFilter] = useQueryState('status', parseAsString.withDefault('all'));
|
||||
|
||||
// --- Local State ---
|
||||
|
||||
Reference in New Issue
Block a user