View | Details | Raw Unified | Return to bug 22835
Collapse All | Expand All

(-)a/Koha/REST/Plugin/PluginRoutes.pm (-2 / +1 lines)
Lines 48-60 sub register { Link Here
48
    if (   C4::Context->preference('UseKohaPlugins')
48
    if (   C4::Context->preference('UseKohaPlugins')
49
        && C4::Context->config("enable_plugins") )
49
        && C4::Context->config("enable_plugins") )
50
    {
50
    {
51
        # plugin needs to define a namespace
51
        @plugins = Koha::Plugins->new()->GetPlugins(
52
        @plugins = Koha::Plugins->new()->GetPlugins(
52
            {
53
            {
53
                method => 'api_namespace',
54
                method => 'api_namespace',
54
            }
55
            }
55
        );
56
        );
56
        # plugin needs to define a namespace
57
        #@plugins = grep { $_->api_namespace } @plugins;
58
    }
57
    }
59
58
60
    foreach my $plugin ( @plugins ) {
59
    foreach my $plugin ( @plugins ) {
(-)a/Koha/REST/V1/Static.pm (-2 lines)
Lines 68-74 sub get { Link Here
68
        return try {
68
        return try {
69
            my $asset = Mojo::Asset::File->new(path => join('/', $basepath, $relpath));
69
            my $asset = Mojo::Asset::File->new(path => join('/', $basepath, $relpath));
70
            return $c->render({ status => 404, openapi => { error => 'File not found' } }) unless $asset->is_file;
70
            return $c->render({ status => 404, openapi => { error => 'File not found' } }) unless $asset->is_file;
71
            # $c->res->headers->content_type("image/jpeg");
72
            return $c->reply->asset($asset);
71
            return $c->reply->asset($asset);
73
        }
72
        }
74
        catch {
73
        catch {
75
- 

Return to bug 22835