Symfony \ Component \ Debug \ Exception \ FatalThrowableError (E_ERROR)
Call to undefined function App\Http\Controllers\ThreadsCollection() Symfony\Component\Debug\Exception\FatalThrowableError thrown with message "Call to undefined function App\Http\Controllers\ThreadsCollection()" Stacktrace: #0 Symfony\Component\Debug\Exception\FatalThrowableError in /home/bkains/Git/GamingForum/app/Http/Controllers/ThreadController.php:68
Application frames (1) All frames (1)
0
Symfony
\
Component
\
Debug
\
Exception
\
FatalThrowableError
/
app
/
Http
/
Controllers
/
ThreadController.php
68
/
home
/
bkains
/
Git
/
GamingForum
/
app
/
Http
/
Controllers
/
ThreadController.php
    public function store(Request $request)
    {
        $thread = new Thread;
        
        $thread->thread_title = $request->thread_title;
        $thread->thread_creator_id = $request->user_id;
 
        $thread->save();
    }
 
    /**
     * Display the specified resource.
     *
     * @param integer $id
     *  - A thread ID
     * @return \Illuminate\Http\Response
     */
    public function show(int $id)
    {
        $thread = ThreadsCollection(Thread::find($id)->with("posts")->get());
        return view("thread_view")->withThread($thread);
    }
 
    /**
     * Update the specified resource in storage.
     *
     * @param  \Illuminate\Http\Request  $request
     * @param  \App\Thread  $thread
     * @return \Illuminate\Http\Response
     */
    public function update(Request $request, Thread $thread)
    {
        $thread->thread_title = $request->thread_title;
        $thread->save();
    }
 
    /**
     * Remove the specified resource from storage.
     *
     * @param  \App\Thread  $thread
Arguments
  1. "Call to undefined function App\Http\Controllers\ThreadsCollection()"
    

Environment & details:

empty
empty
empty
empty
empty
Key Value
DOCUMENT_ROOT
"/home/bkains/Git/GamingForum/public"
REMOTE_ADDR
"127.0.0.1"
REMOTE_PORT
"49676"
SERVER_SOFTWARE
"PHP 7.2.16 Development Server"
SERVER_PROTOCOL
"HTTP/1.1"
SERVER_NAME
"127.0.0.1"
SERVER_PORT
"8000"
REQUEST_URI
"/api/thread/1"
REQUEST_METHOD
"GET"
SCRIPT_NAME
"/index.php"
SCRIPT_FILENAME
"/home/bkains/Git/GamingForum/public/index.php"
PATH_INFO
"/api/thread/1"
PHP_SELF
"/index.php/api/thread/1"
CONTENT_TYPE
"application/x-www-form-urlencoded"
HTTP_CONTENT_TYPE
"application/x-www-form-urlencoded"
HTTP_CACHE_CONTROL
"no-cache"
HTTP_POSTMAN_TOKEN
"96c14108-10d7-4b48-8a8b-4aaa8a00e19e"
HTTP_USER_AGENT
"PostmanRuntime/7.6.1"
HTTP_ACCEPT
"*/*"
HTTP_HOST
"localhost:8000"
HTTP_ACCEPT_ENCODING
"gzip, deflate"
HTTP_CONNECTION
"keep-alive"
REQUEST_TIME_FLOAT
1554837063.3276
REQUEST_TIME
1554837063
empty
0. Whoops\Handler\PrettyPageHandler