mirror of
https://github.com/TryGhost/Ghost.git
synced 2024-12-15 19:52:01 +03:00
13 lines
381 B
JavaScript
13 lines
381 B
JavaScript
var CSRFInitializer = {
|
|
name: 'csrf',
|
|
|
|
initialize: function (container, application) {
|
|
application.register('csrf:current', $('meta[name="csrf-param"]').attr('content'), { instantiate: false });
|
|
|
|
application.inject('route', 'csrf', 'csrf:current');
|
|
application.inject('controller', 'csrf', 'csrf:current');
|
|
}
|
|
};
|
|
|
|
export default CSRFInitializer;
|