save_pod_item saves everything twice

0

This is something strange, but when i try to add new pod item with my own code, records are just duplicating (the only difference is the id column), and i'm sure that save_pod_item is used only once. What could be wrong?

Update: I've changed one of the columns to be unique, that can be a sloution for me, but it can be unacceptable in other cases.

asked Jan 7 '11 at 11:53

Fike

208

edited Jan 8 '11 at 12:10

add comment
enter at least 15 characters

1 Answer

0

Are you by chance using save_post_item in the 'save_post' hook? If so, you need to do a check to make sure the current action is not a revision or an autosave, otherwise, you'll get duplicates.

answered Jan 11 '11 at 2:27

Mike Van Winkle

219

add comment
enter at least 15 characters