fixing POST/PUT operations not saving to file