Merge pull request #802 from trheyi/main

Improve error message for missing app.yao file for better clarity
This commit is contained in:
Max 2024-12-03 16:42:12 +08:00 committed by GitHub
commit 0bcb56a654
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
2 changed files with 2 additions and 2 deletions

View file

@ -67,7 +67,7 @@ var startCmd = &cobra.Command{
// Is Yao App
if !setup.IsYaoApp(config.Conf.Root) {
fmt.Println(color.RedString(L("yao.app not found")))
fmt.Println(color.RedString("The app.yao file is missing"))
os.Exit(1)
}

View file

@ -73,7 +73,7 @@ func (r *Request) NewData() Data {
data["$query"] = r.Query
data["$param"] = r.Params
data["$cookie"] = cookies
data["$url"] = r.URL
data["$url"] = r.URL.Map()
data["$theme"] = r.Theme
data["$locale"] = r.Locale
data["$timezone"] = GetSystemTimezone()