Skip to content

Commit

Permalink
Fix return type to prevent promise error (alfredfrancis#98)
Browse files Browse the repository at this point in the history
  • Loading branch information
alfredfrancis authored Jul 26, 2018
1 parent 3d3e2ba commit 25a0014
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion app/entities/controllers.py
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@ def update_entity(id):
entity = Entity.objects.get(id=ObjectId(id))
entity = update_document(entity, json_data)
entity.save()
return 'success', 200
return build_response.sent_ok()


@entities_blueprint.route('/<id>', methods=['DELETE'])
Expand Down
4 changes: 2 additions & 2 deletions frontend/src/app/agent/entity/entity.component.ts
Original file line number Diff line number Diff line change
Expand Up @@ -55,8 +55,8 @@ export class EntityComponent implements OnInit {
}
saveEntity(){
this.entitiesService.saveEntity(this.entity).then(
(result)=>{
console.log(result);
(result:any)=>{
console.log("Success: " + JSON.stringify(result));
}
)
}
Expand Down

0 comments on commit 25a0014

Please sign in to comment.