Skip to content

Commit

Permalink
Update dependencies (#78)
Browse files Browse the repository at this point in the history
(cherry picked from commit 3218fd9)
  • Loading branch information
ottenhoff committed Apr 11, 2024
1 parent 3461071 commit 47b0eb3
Show file tree
Hide file tree
Showing 8 changed files with 61 additions and 25 deletions.
23 changes: 23 additions & 0 deletions .github/workflows/maven.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
# This workflow will build a Java project with Maven
# For more information see: https://help.github.com/actions/language-and-framework-guides/building-and-testing-java-with-maven

name: Java CI with Maven

on:
pull_request:

jobs:
maven-build:
runs-on: ubuntu-22.04
steps:
- name: Git Checkout
uses: actions/checkout@v4
- name: JDK 11
uses: actions/setup-java@v4
with:
java-version: 11
distribution: 'temurin'
- name: Build with Maven
env:
MAVEN_OPTS: -Djava.awt.headless=true -Dorg.slf4j.simpleLogger.defaultLogLevel=info -Dmaven.wagon.http.retryHandler.count=2 -Dmaven.wagon.http.pool=true
run: mvn clean install -Psnapshots -V -B
4 changes: 0 additions & 4 deletions api/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -35,10 +35,6 @@
<groupId>org.sakaiproject.search</groupId>
<artifactId>search-api</artifactId>
</dependency>
<dependency>
<groupId>commons-lang</groupId>
<artifactId>commons-lang</artifactId>
</dependency>
<dependency>
<groupId>org.projectlombok</groupId>
<artifactId>lombok</artifactId>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,6 @@
import java.util.Date;
import java.util.Stack;

import org.apache.commons.lang.StringEscapeUtils;
import org.sakaiproject.clog.api.ClogManager;
import org.sakaiproject.clog.api.cover.SakaiProxy;
import org.sakaiproject.entity.api.Entity;
Expand Down Expand Up @@ -68,8 +67,7 @@ public void setContent(String text, boolean modified) {
if (!this.content.equals(text) && modified) {
modifiedDate = new Date().getTime();
}

this.content = StringEscapeUtils.unescapeHtml(text.trim());
this.content = text;
}

public String getContent() {
Expand Down
4 changes: 0 additions & 4 deletions impl/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -51,10 +51,6 @@
<groupId>org.springframework</groupId>
<artifactId>spring-beans</artifactId>
</dependency>
<dependency>
<groupId>commons-lang</groupId>
<artifactId>commons-lang</artifactId>
</dependency>
<dependency>
<groupId>junit</groupId>
<artifactId>junit</artifactId>
Expand Down
26 changes: 25 additions & 1 deletion pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,6 @@
<groupId>org.sakaiproject</groupId>
<artifactId>master</artifactId>
<version>23-SNAPSHOT</version>
<relativePath>../master/pom.xml</relativePath>
</parent>

<name>CLOG</name>
Expand Down Expand Up @@ -44,5 +43,30 @@
</dependency>
</dependencies>
</dependencyManagement>

<profiles>
<profile>
<id>snapshots</id>
<activation>
<activeByDefault>false</activeByDefault>
<property>
<name>snapshots</name>
</property>
</activation>
<repositories>
<repository>
<id>sonatype-nexus-snapshots</id>
<name>Sonatype Nexus Snapshots</name>
<url>https://oss.sonatype.org/content/repositories/snapshots</url>
<releases>
<enabled>false</enabled>
</releases>
<snapshots>
<enabled>true</enabled>
</snapshots>
</repository>
</repositories>
</profile>
</profiles>

</project>
15 changes: 8 additions & 7 deletions tool/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -56,22 +56,23 @@
<artifactId>javax.servlet-api</artifactId>
</dependency>
<dependency>
<groupId>commons-lang</groupId>
<artifactId>commons-lang</artifactId>
<groupId>org.apache.commons</groupId>
<artifactId>commons-lang3</artifactId>
</dependency>
<dependency>
<groupId>org.projectlombok</groupId>
<artifactId>lombok</artifactId>
</dependency>
<dependency>
<groupId>javax.servlet</groupId>
<artifactId>jstl</artifactId>
<groupId>jakarta.servlet.jsp.jstl</groupId>
<artifactId>jakarta.servlet.jsp.jstl-api</artifactId>
<version>${sakai.jakarta.jstl-api.version}</version>
<scope>compile</scope>
</dependency>
<dependency>
<groupId>taglibs</groupId>
<artifactId>standard</artifactId>
<version>1.1.2</version>
<groupId>org.apache.taglibs</groupId>
<artifactId>taglibs-standard-impl</artifactId>
<version>1.2.5</version>
<scope>compile</scope>
</dependency>
</dependencies>
Expand Down
4 changes: 2 additions & 2 deletions tool/src/java/org/sakaiproject/clog/tool/ClogTool.java
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;

import org.apache.commons.lang.StringEscapeUtils;
import org.apache.commons.lang3.StringEscapeUtils;
import org.sakaiproject.clog.api.ClogManager;
import org.sakaiproject.clog.api.SakaiProxy;
import org.sakaiproject.component.api.ComponentManager;
Expand Down Expand Up @@ -107,7 +107,7 @@ protected void doGet(HttpServletRequest request, HttpServletResponse response) t
request.setAttribute("sakaiHtmlHead", (String) request.getAttribute("sakai.html.head"));

request.setAttribute("userId", userId);
request.setAttribute("userDisplayName", StringEscapeUtils.escapeJavaScript(displayName));
request.setAttribute("userDisplayName", StringEscapeUtils.escapeEcmaScript(displayName));
request.setAttribute("siteId", siteId);
request.setAttribute("state", state);

Expand Down
6 changes: 2 additions & 4 deletions tool/src/webapp/WEB-INF/functions.tld
Original file line number Diff line number Diff line change
Expand Up @@ -28,9 +28,7 @@

<function>
<name>escapeJS</name>
<!--<function-class>org.apache.commons.lang3.StringEscapeUtils</function-class>-->
<!--<function-signature>java.lang.String escapeEcmaScript(java.lang.String)</function-signature>-->
<function-class>org.apache.commons.lang.StringEscapeUtils</function-class>
<function-signature>java.lang.String escapeJavaScript(java.lang.String)</function-signature>
<function-class>org.apache.commons.lang3.StringEscapeUtils</function-class>
<function-signature>java.lang.String escapeEcmaScript(java.lang.String)</function-signature>
</function>
</taglib>

0 comments on commit 47b0eb3

Please sign in to comment.