mirror of
https://github.com/discourse/discourse.git
synced 2025-01-26 15:20:46 +08:00
13 lines
336 B
JavaScript
13 lines
336 B
JavaScript
import { ajax } from 'discourse/lib/ajax';
|
|
import RestAdapter from 'discourse/adapters/rest';
|
|
|
|
export default RestAdapter.extend({
|
|
find(store, type, findArgs) {
|
|
if (findArgs.similar) {
|
|
return ajax("/topics/similar_to", { data: findArgs.similar });
|
|
} else {
|
|
return this._super(store, type, findArgs);
|
|
}
|
|
}
|
|
});
|