Skip to content

Conversation

@thevaibhav-dixit
Copy link
Contributor

No description provided.

Comment on lines +386 to +405
let #name: #ty = #ident.#accessor.clone();
}
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@bodymindarts maybe you can help me fig out how I can avoid clone here.

entities: Vec<#entity>,
) -> Result<Vec<#entity>, #error> {
if entities.is_empty() {
return Ok(Vec::new());
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

can simply return entities.


let sql_updates = self.columns.sql_updates();

let update_fragment = format!("UPDATE {table_name} SET {sql_updates} WHERE id = $1");
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This can't be right - it needs to handle multiple ids.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants