fix on rest server script