Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Input.php get, post 属性没定义时。 #98

Open
wuchuguang opened this issue Oct 26, 2017 · 2 comments
Open

Input.php get, post 属性没定义时。 #98

wuchuguang opened this issue Oct 26, 2017 · 2 comments

Comments

@wuchuguang
Copy link

$this->request->post[$index] ?? ''
改为
$this->request->post[$index] ?? null

这样更合适。因为这个值null可以再用 ??

@viaweb3
Copy link
Contributor

viaweb3 commented Oct 28, 2017

建议提交一个PR,我们考虑一下,合适的话就直接合并。

@wuchuguang
Copy link
Author

/**
     * 获取GET参数
     *
     * @param string $index GET参数名
     * @return string
     */
    public function get($index)
    {
        return $this->request->get[$index] ?? '';//还没~~~
    }

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants