# Chapter 7 - Type of expression is ambiguous without more context - Unable to build

**URL:** <https://forums.kodeco.com/t/chapter-7-type-of-expression-is-ambiguous-without-more-context-unable-to-build/63725>\
**Category:** Server Side Swift with Vapor\
**Created:** [March 5, 2019, 4:40pm UTC](https://forums.kodeco.com/t/chapter-7-type-of-expression-is-ambiguous-without-more-context-unable-to-build/63725 "2019-03-05T16:40:29Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![rniller](https://assets.chunter.kodeco.com/user_avatar/forums.kodeco.com/rniller/32/80626_2.png) [@rniller](https://forums.kodeco.com/u/rniller)\
**Post date:** [March 5, 2019, 4:40pm UTC](https://forums.kodeco.com/t/chapter-7-type-of-expression-is-ambiguous-without-more-context-unable-to-build/63725/1 "2019-03-05T16:40:29Z")

</div>

I’m thrown an expression error of “Type of expression is ambiguous without more context” on the line expressing the return when running this router code.

```
// Search
    router.get("API", "acronyms", "search") { req -> Future<Acronym> in
        guard
            let searchTerm = req.query[String.self, at: "term"] else {
                throw Abort(.badRequest)
        }
        return Acronym.query(on: req)
        .filter(.short == searchTerm)
        .all()
    }

```

![02%20AM](https://files.chunter.kodeco.com/original/3X/d/a/da500bf8a2dc70dcfa52db146eb1d037959ed562.jpeg)

Anyone know why I am getting this error?

**Update:**

I was missing `Import Fluent`.

---

<div class="post-metadata">

**Author:** ![shogunkaramazov](https://assets.chunter.kodeco.com/user_avatar/forums.kodeco.com/shogunkaramazov/32/108826_2.png) [@shogunkaramazov](https://forums.kodeco.com/u/shogunkaramazov)\
**Post date:** [March 5, 2019, 5:21pm UTC](https://forums.kodeco.com/t/chapter-7-type-of-expression-is-ambiguous-without-more-context-unable-to-build/63725/2 "2019-03-05T17:21:21Z")

</div>

@rniller Glad you fixed it! :]

---

<div class="post-metadata">

**Author:** ![rniller](https://assets.chunter.kodeco.com/user_avatar/forums.kodeco.com/rniller/32/80626_2.png) [@rniller](https://forums.kodeco.com/u/rniller)\
**Post date:** [March 5, 2019, 5:23pm UTC](https://forums.kodeco.com/t/chapter-7-type-of-expression-is-ambiguous-without-more-context-unable-to-build/63725/3 "2019-03-05T17:23:35Z")

</div>

Lol rookie mistake on my part 😛 Btw, this book is amazing! I’m so glad I stumbled upon it.
