Fixed bug in angularjs service.

Now alerts that arise during folder management should be displayed properly.