Skip to content

$model->update() doesn't appear to work. #62

Closed
@trea

Description

@trea

Hey there,

One issue I've stumbled upon is Eloquent's $model->update() not working properly. I verify this by using DB::getQueryLog() method to dump out queries. If a property is save via

$model->property = "blah";
$model->save();

it works great. But if it's done like so:

$post = Post::where('id', $id)->get()->first();
$post->update(Input::except('_id'));

It only ever runs the query to find the model.

Perhaps I'm missing something here?

Thanks,
Trea

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions