| Conditions | 1 |
| Paths | 1 |
| Total Lines | 12 |
| Code Lines | 6 |
| Lines | 0 |
| Ratio | 0 % |
| Changes | 1 | ||
| Bugs | 0 | Features | 1 |
| 1 | <?php |
||
| 39 | public function sendTweet(Request $request) |
||
| 40 | { |
||
| 41 | $this->validate($request, [ |
||
| 42 | 'tweet' => 'required', |
||
| 43 | ]); |
||
| 44 | |||
| 45 | $tweet = $request->input('tweet') . ' #LaravelHackathonStarter'; |
||
| 46 | |||
| 47 | Twitter::postTweet(['status' => $tweet, 'format' => 'json']); |
||
| 48 | |||
| 49 | return redirect()->back()->with('info','Your Tweet has been posted successfully'); |
||
| 50 | } |
||
| 51 | } |
||
| 52 |