[enc] Fix bug of indexing file on the server.