Skip to content

Need to support upsert function in Laravel 10 #2718

Closed
@zyz954489346

Description

@zyz954489346
  • Laravel-mongodb Version: 4.1
  • PHP Version: 8.3
  • Database Driver & Version: 4

Description:

The implementation of Cache's put function is modified to db's upsert function in Laravel10.
image

Steps to reproduce

When the driver of cache is changed to mongodb,This will lead to an error. Such as this:

 \Cache::store('mongdb-conn')->forever($key, $val);

// or 
 \Cache::store('mongdb-conn')->put($key, $val);

The error is: This database engine does not support upserts.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions