refactored permission system and error handling

This commit is contained in:
2025-09-26 15:35:54 +02:00
parent 2cfd6248bc
commit d025819888
26 changed files with 2312 additions and 300 deletions

View File

@ -156,9 +156,8 @@ pub fn select(
// Stelle sicher, dass es eine Query ist
if !matches!(statement, Statement::Query(_)) {
return Err(DatabaseError::UnsupportedStatement {
statement_type: "Non-Query".to_string(),
description: "Only SELECT statements are allowed in select function".to_string(),
return Err(DatabaseError::StatementError {
reason: "Only SELECT statements are allowed in select function".to_string(),
});
}