CubDB.update

You're seeing just the function update, go back to CubDB module for more information.
Link to this function

update(db, key, initial, fun)

View Source

Specs

update(GenServer.server(), key(), value(), (value() -> value())) :: :ok

Updates the entry corresponding to key using the given function.

If key is present in the database, fun is invoked with the corresponding value, and the result is set as the new value of key. If key is not found, initial is inserted as the value of key.

The return value is :ok, or {:error, reason} in case an error occurs.